GATE CS 2022 Set 1 — Question 64
Go beyond PYQs with Success TrackerAI-powered personalised practice and doubt support. Unlimited practice on eligible plans; AI usage limits apply.NAT+2 / -0MediumPage Replacement AlgorithmsMemory ManagementOperating SystemDemand Paging
Operating System → Memory Management → Demand Paging
Last updated
Question
Consider a demand paging system with four page frames (initially empty) and LRU page replacement policy. For the following page reference stringthe page fault rate, defined as the ratio of number of page faults to the number of memory accesses (rounded off to one decimal place) is _________.
Correct answer
0.6 to 0.6
Solution
To find the page fault rate, we trace the memory accesses using the LRU (Least Recently Used) policy with 4 frames:
Total number of page faults = 9
Page fault rate =
1.7: Page Fault. Frames: [7]
2.2: Page Fault. Frames: [7, 2]
3.7: Page Hit. Frames: [2, 7] (7 is now most recently used)
4.3: Page Fault. Frames: [2, 7, 3]
5.2: Page Hit. Frames: [7, 3, 2] (2 is now most recently used)
6.5: Page Fault. Frames: [7, 3, 2, 5]
7.3: Page Hit. Frames: [7, 2, 5, 3] (3 is now most recently used)
8.4: Page Fault. Replace 7 (least recently used). Frames: [2, 5, 3, 4]
9.6: Page Fault. Replace 2 (least recently used). Frames: [5, 3, 4, 6]
10.7: Page Fault. Replace 5 (least recently used). Frames: [3, 4, 6, 7]
11.7: Page Hit. Frames: [3, 4, 6, 7]
12.1: Page Fault. Replace 3 (least recently used). Frames: [4, 6, 7, 1]
13.5: Page Fault. Replace 4 (least recently used). Frames: [6, 7, 1, 5]
14.6: Page Hit. Frames: [7, 1, 5, 6]
15.1: Page Hit. Frames: [7, 5, 6, 1]
Total number of memory accesses = 15Total number of page faults = 9
Page fault rate =
Continue learning with Success Tracker
A step still unclear? Work through it with support
Use Success Tracker to ask about the reasoning, then try another GATE CS question to check your understanding.
AI-powered practice· Unlimited practice on eligible plans
- PYQs with solutions
- Attempt available previous-year questions, then compare your reasoning with the worked solution. Coverage varies by stream.
- Practice that adapts
- Choose a topic, work on weaker areas and bookmark questions to revisit. Your attempts feed your progress tracking.
- AI doubt support
- Ask follow-up questions about a step or concept while practising, instead of stopping at the final answer.
Unlimited practice is available on eligible plans. Free practice and AI usage have limits; check the current plan allowances before choosing.
This page stays readable without an account. AI responses can be wrong; check them against the solution and source material.
More questions on Memory Management
2026 Set 2 Q23Which one of the following CPU scheduling algorithms cannot be preemptive?2026 Set 1 Q29With respect to deadlocks in an operating system, which of the following statements is/are FALSE?2026 Set 1 Q31In the context of relational database normalization, which of the following statements is/are true?2026 Set 1 Q35Consider a system consisting of instances of a resource , being shared by 5 processes.…2026 Set 2 Q51Consider three processes P1, P2, and P3 running identical code, as shown in the pseudocode below. A…