CS!
Views: 6719
moaaz ki mcqs file to upload kr den plz
mcq's
Thank u so much :) :)
My Pleasure.....
subjective
subjec questions kia thy wo bataeennn wohi tou important hy???
Ans to Qno21
#include <stdio.h>
#include <stdlib.h>
#include <pthread.h>
/* Prototype for a function to be passed to our thread */
void* MyThreadFunc(void *arg);
int main()
{
pthread_t newThread;
/* Create a thread and have it run the MyThreadFunction */
pthread_create(&newThread, NULL, MyThreadFunc, NULL);
return 0;
}
void* MyThreadFunc(void* arg)
{
printf ("The thread.\n");
return NULL;
}
Q22
A CPU scheduler has different evaluation matrices and average waiting time is one of them. State how waiting time relates to the evaluation of matrices with respect to CPU scheduling.
Answer
The time spent on the ready queue is the “waiting time” which is one of the evaluation criteria for the CPU scheduler matrices/algorithms. CPU schedulers aim at minimizing average waiting time of processes. However, average waiting time is different in case of different scheduling algorithms
Q23 identify three reasons why mknod() system call fails
Answer
Some of the reasons for this call to fail are:
File with the given name exists
Pathname too long
A component in the pathname not searchable, non-existent, or non-directory
Destination directory is read-only
Not enough memory space available
Signal caught during the execution of mknod()
Q24. What will happen if exit() is called instead of pthread_exit() in multithreaded system?
Answer
When a thread terminates with the exit() system call, it terminates the whole process because the purpose of the exit() system call is to terminate a process and not a thread.
Q25
Q26
Ans
Here are the waiting times for the three processes and the average waiting time per process.
Waiting times P1 = 0; P2 = 24; P3 = 27 turnaround time per process
Average waiting time: (0+24+27)/3 = 17 average turn around time per process
Independent
which question?
ho gya paper ?
aoa.mcqs aur subjective ki bari me btai moaz file si ai he ya nahe .
subjective bhi moaz file si aia ha k nahe .ya conceptual ha .
midterm me ktni lecture he.
1-18 lecture and i dont mera paper kal hai......
© 2021 Created by + M.Tariq Malik.
Promote Us | Report an Issue | Privacy Policy | Terms of Service