CS FundamentalsHardGATE CS (PYQ pattern)
Round Robin, quantum 4 ms, four processes arriving together at time 0 in the order P1..P4 with bursts 9, 5, 2 and 6 ms. Every switch to a different process costs 1 ms of dead time, and none is incurred when the same process continues. What is the average turnaround time?
- A. 18 ms
- B. 24 ms
- C. 21.5 ms
- D. 23 ms
Correct answer: D. 23 ms
Completion times with the overhead: {2: 12, 1: 24, 3: 27, 0: 29}; the mean is 23 ms. Without overhead the mean is 18 ms.
More Operating Systems questions
- A system has 48-bit virtual addresses, 8 KB pages and 2^40 bytes of physical memory. Each page-table entry holds a frame number plus 5…
- A 7200 RPM disk has 500 sectors of 512 bytes per track and an average seek of 8 ms. A 1,048,576-byte file is stored in consecutive sectors…
- A program loops over pages 1, 2, 3, 4, 5 six times in cyclic order (30 references) with 4 frames, initially empty. How many page faults…
- SJF predicts each process's next CPU burst by exponential averaging, tau(n+1) = a x t(n) + (1 - a) x tau(n), with a = 0.5 and tau(0) = 10…
- Assume every fork() succeeds. for (int i = 0; i < 4; i++) { if (fork() == 0 && i % 2 == 1) execl("/bin/true", "true", NULL); }…
- A machine with 4 KB pages and demand paging has a 6-byte memory-to-memory MOVE instruction stored at virtual address 0x0FFC. It copies 300…