Q1 a. What is an operating system? Explain its various functions.
b. Explain shortest job first scheduling (SJFS) technique with example.
Q2 a. What is deadlock? Give necessary conditions for deadlock. b. Calculate average waiting time using priority scheduling. Process Burst Time Priority P1 10 3 P2 1 1 P3 2 4 P4 1 5 P5 5 2 Q3 a. What are different process states ? Draw a diagram for process control block (PCB). b. Consider a system with five processes P0 through P4 and three resource types A,B,C. Resource type A has 10 instances, resource type B has 5 instances and resource type C has 7 instances. Suppose that at time T0, the following snapshot of the system has been taken, then solve using safety algorithm. Allocation Max Available ABC ABC AB C P0 0 1 0 7 5 3 3 3 2 P1 2 0 0 3 2 2 P2 3 0 2 9 0 2 P3 2 1 1 2 2 2 P4 0 0 2 4 3 3 Q4 a. What is a thread ? Differentiate between multiprogramming and multiprocessing. b. Given memory partition of 100 Kb, 500 Kb, 200 Kb, 300 Kb and 600 Kb in order, have would each of the first fit , best fit and worst fit algo. Place processes of 212 Kb, 417 Kb, 112 Kb and 426 Kb in order. Which algo match the most efficient use of memory.