StudyFox
कीमतेंब्लॉगएक्सटेंशनमुफ़्त टूल
  • कीमतें
  • ब्लॉग
  • एक्सटेंशन
  • मुफ़्त टूल
  • शुरू करेंसाइन इन
StudyFox

अपने नोट्स, PDF और स्लाइड्स को फ़्लैशकार्ड, क्विज़, नोट्स और माइंड मैप में बदलें।

StudyFox खोलें

स्टडी टूल्स

  • होमवर्क हेल्पर
  • नोट मेकर
  • फ़्लैशकार्ड मेकर
  • क्विज़ मेकर
  • माइंड मैप मेकर

प्रोडक्ट

  • कीमतें
  • Chrome एक्सटेंशन
  • मुफ़्त एक्सटेंशन
  • स्टडी सेट देखें
  • ब्लॉग

सहायता

  • सहायता केंद्र
  • संपर्क करें
  • गोपनीयता नीति
  • सेवा की शर्तें

तुलना करें

  • Chegg का विकल्प
  • Course Hero का विकल्प
  • Coursology का विकल्प
  • Photomath का विकल्प
  • Gauthmath का विकल्प
  • PhotoSolve का विकल्प
  • CollegeTools का विकल्प
  • Transcript का विकल्प
  • SmartSolve का विकल्प
  • Homeworkify का विकल्प
  • AnswersAi का विकल्प
  • StudyX का विकल्प
  • Quizlet का विकल्प
  • Anki का विकल्प
  • Knowt का विकल्प
  • Brainscape का विकल्प
  • सभी तुलनाएँ

© 2026 StudyFox AI. सर्वाधिकार सुरक्षित।

  • X
  • Discord
  • Instagram
ExploreEngineering & TechComputer ScienceOperating Systems Quiz: Processes, Scheduling, Memory and Deadlock

Quiz · Medium

Operating Systems Quiz: Processes, Scheduling, Memory and Deadlock

Twenty questions on process states, threads, scheduling calculations, paging, page replacement, inodes, deadlock and kernel design with diagrams.

by Kill h.20 questionsCreated Nov 20, 2026, 08:26 PM
Computer Science· Operating SystemsTags#operating-systems#processes#memory#quiz

20 questions

  1. 1

    In this process-state diagram, what does the state labelled 'Waiting' (in main memory, linked both to and from Running) represent?

    • A

      A process blocked on I/O

    • B

      A terminated process

    • A process ready to run, waiting for the CPU

    • D

      A process swapped out to disk

    Here 'Waiting' is the ready queue: the process is in memory and runnable, and the scheduler can dispatch it. The blocked state is the separate box that waits for an event. Many books call this state Ready.

  2. 2

    Which transition is NOT possible in the standard five-state process model?

    • Blocked → Running

    • B

      Ready → Running

    • C

      Running → Blocked

    • D

      Running → Ready

    When the awaited event occurs a blocked process moves to Ready and must be chosen again by the scheduler; it never goes straight to Running.

  3. 3

    After fork() in a Unix program, what value does the child process receive as fork()'s return value?

    • A

      The parent's PID

    • B

      The child's PID

    • C

      −1

    • 0

    fork() returns 0 in the child and the child's PID in the parent. −1 signals failure in C.

  4. 4

    Which statement about threads of the same process is true?

    • A

      They share the same stack

    • They share the same heap and global data

    • C

      They each have a separate address space

    • D

      They cannot run in parallel

    Threads share code, heap, globals and open files, but each has its own stack and registers. Separate address spaces are what distinguish processes.

  5. 5

    Three jobs arrive together: P1 = 24 ms, P2 = 3 ms, P3 = 3 ms. What is the average waiting time under FCFS in the order P1, P2, P3?

    • A

      3 ms

    • B

      5.67 ms

    • 17 ms

    • D

      27 ms

    Waits are 0, 24 and 27: (0 + 24 + 27) / 3 = 17 ms. Running the short jobs first (SJF) gives 3 ms, the convoy effect in action.

  6. 6

    Round robin with quantum 4 ms on P1 = 24, P2 = 3, P3 = 3 (all arrive at 0). What is P3's waiting time?

    • 7 ms

    • B

      4 ms

    • C

      6 ms

    • D

      10 ms

    P1 runs 0–4, P2 4–7, then P3 starts at 7, so it waited 7 ms. P1 waited 6 and P2 waited 4.

  7. 7

    Which scheduling algorithm minimizes the average waiting time (for a given set of jobs that are all available)?

    • A

      Round robin

    • B

      FCFS

    • C

      Priority scheduling

    • Shortest job first

    SJF is provably optimal for average waiting time, but real systems must estimate burst lengths.

  8. 8

    What does aging prevent in priority scheduling?

    • A

      Deadlock

    • Starvation

    • C

      Thrashing

    • D

      Fragmentation

    Aging gradually increases the priority of processes that have waited a long time, so low-priority processes eventually run.

  9. 9

    A system uses 4 KiB pages. A virtual address is 0x3A4. Which virtual page number and offset does it have?

    • A

      Page 3, offset 0xA4

    • B

      Page 0, offset 0x3

    • Page 0, offset 0x3A4

    • D

      Page 3, offset 0x4

    4 KiB = 0x1000 bytes, so addresses below 0x1000 are in page 0 and the offset is the whole address. Splitting by hex digits (page 3) would only be right for 256-byte pages.

  10. 10

    With 4 KiB pages and 32-bit virtual addresses, how many bits are used for the virtual page number?

    • 20

    • B

      10

    • C

      12

    • D

      32

    The offset needs 12 bits (2¹² = 4096), leaving 32 − 12 = 20 bits for the page number.

  11. 11

    The diagram shows virtual page 3 mapped to frame 7 with offset 0x2A4 and 4 KiB pages. What is the physical address?

    • A

      0x32A4

    • B

      0x7000

    • C

      0x2A47

    • 0x72A4

    Physical address = frame × page size + offset = 7 × 0x1000 + 0x2A4 = 0x72A4. The offset is copied unchanged.

  12. 12

    What is the purpose of the TLB?

    • A

      To store the page table on disk

    • To cache recent page-to-frame translations

    • C

      To schedule processes

    • D

      To track free disk blocks

    A TLB hit avoids a page-table walk, which would cost an extra memory access.

  13. 13

    How many page faults does FIFO produce with 3 frames on the reference string 7 0 1 2 0 3 0 4 2 3 0 3 (see the figure)?

    • A

      8

    • B

      9

    • 10

    • D

      12

    Only the second reference to 0 and the last 3 hit: 10 faults. The first three references are faults too, because the frames start empty.

  14. 14

    True or false: giving a process more physical frames never increases the number of page faults under FIFO.

    • A

      True

    • False

    Belady's anomaly: on 1 2 3 4 1 2 5 1 2 3 4 5, FIFO gives 9 faults with 3 frames and 10 with 4.

  15. 15

    Which problem does paging eliminate but segmentation can suffer from?

    • External fragmentation

    • B

      Internal fragmentation

    • C

      Page faults

    • D

      Context switching

    Paging uses fixed-size blocks, so there are no unusable holes between allocations. It still suffers a little internal fragmentation in the last page.

  16. 16

    In the inode diagram, what do the pointers 13, 14 and 15 lead to?

    • A

      Direct data blocks

    • B

      Directory entries

    • C

      The file name

    • Indirect, double indirect and triple indirect blocks of pointers

    The first pointers address data blocks directly; the later ones point to blocks of pointers that extend the maximum file size. Image: timtjtim, CC BY-SA 4.0, via Wikimedia Commons.

  17. 17

    Process A waits for a lock held by B, and B waits for a lock held by A. Which Coffman condition does this cycle of waiting describe?

    • A

      Mutual exclusion

    • Circular wait

    • C

      No preemption

    • D

      Bounded waiting

    Each process waits for a resource held by the next, closing a cycle. Bounded waiting is a critical-section requirement, not a Coffman condition.

  18. 18

    In the resource-allocation graph, P1 holds R1 and requests R2 while P2 holds R2 and requests R1. What is the state of the system?

    • A

      Safe

    • B

      Starving but not deadlocked

    • Deadlocked

    • D

      Livelocked

    A cycle with single-instance resources means deadlock: neither process can proceed.

  19. 19

    Which statement about a binary semaphore versus a mutex is most accurate?

    • A mutex has an owner that should unlock it; a semaphore can be signalled by a different thread

    • B

      They are identical in every respect

    • C

      A semaphore cannot be used for synchronization

    • D

      A mutex can count several resources

    Ownership is the key difference: a semaphore can be signalled by another thread, which makes it suitable for signalling events.

  20. 20

    Which kernel design keeps only minimal functions (scheduling, basic memory management, IPC) in kernel mode?

    • A

      Monolithic kernel

    • B

      Batch kernel

    • C

      Exokernel only

    • Microkernel

    Microkernels move file systems and drivers into user space, improving isolation at the cost of more IPC. Image: Golftheman, public domain, via Wikimedia Commons.