Operating System

161. Let RR3 means Round Robin Scheduling algorithm with time quantum of 3 units and FCFS means First Come First Serve scheduling algorithm. Now if 3 processes P1, P2, P3 have arrival time in order (0, 2, 4) and execution time (8, 5, 4) respectively, then the completion order of P1, P2, P3 under RR3 and FCFS scheduling is:
मान लीजिए RR3 का अर्थ है Round Robin scheduling algorithm with time quantum 3 units और FCFS का अर्थ है First Come First Serve scheduling algorithm। यदि तीन processes P1, P2, P3 के arrival times क्रमशः (0, 2, 4) और execution times (8, 5, 4) हैं, तो RR3 और FCFS में completion order क्या होगा?
(HTET PGT Computer Science 2018)
A. RR3: P2, P1, P3 and FCFS: P3, P2, P1
B. RR3: P3, P2, P1 and FCFS: P1, P2, P3
C. RR3: P2, P1, P3 and FCFS: P1, P2, P3
D. RR3: P1, P2, P3 and FCFS: P3, P2, P1

Correct Answer: C

Explanation (EN): Under FCFS, completion order is P1, P2, P3. Under RR3, the completion order is P2, P1, P3.

Explanation (HI): FCFS में completion order P1, P2, P3 होगा। RR3 में completion order P2, P1, P3 होगा।

162. Priority Scheduling involves assigning a priority value to each process. Which scheduling algorithm is closely related to this concept?
Priority Scheduling में प्रत्येक process को एक priority value दी जाती है। कौन-सा scheduling algorithm इस concept से closely related है?
(Bihar STET Computer Science 12.09.2023 (Shift-II))
A. FCFS
B. SJN
C. Multilevel Queue Scheduling
D. First-Come, First-Served (FCFS)

Correct Answer: C

Explanation (EN): Multilevel Queue Scheduling uses different queues with different priorities, making it closely related to priority scheduling.

Explanation (HI): Multilevel Queue Scheduling में अलग-अलग priority वाली queues होती हैं, इसलिए यह priority scheduling से closely related है।

163. In processor P, non-preemptive priority interrupts 4, 7, 1, 3, 0, 2, 6 arrive sequentially (low number means high priority). If when one interrupt is being handled exactly two more interrupts arrive, what is order of these interrupts handled by P?
Processor P में non-preemptive priority interrupts 4, 7, 1, 3, 0, 2, 6 क्रमशः आते हैं (छोटी संख्या = उच्च priority)। यदि एक interrupt को handle करते समय ठीक दो और interrupts आ जाते हैं, तो इन interrupts को handle करने का क्रम क्या होगा?
(RPSC Computer Science 2016 (Paper-I))
A. 4, 7, 1, 3, 0, 2, 6
B. 4, 1, 3, 0, 2, 6, 7
C. 0, 1, 2, 3, 4, 6, 7
D. 4, 1, 0, 2, 3, 6, 7

Correct Answer: D

Explanation (EN): With non-preemptive priority handling, the processor completes the current interrupt before selecting the highest-priority pending interrupt. The order becomes 4, 1, 0, 2, 3, 6, 7.

Explanation (HI): Non-preemptive priority में processor current interrupt पूरा करता है और फिर pending interrupts में से highest priority वाला चुनता है। इसलिए क्रम 4, 1, 0, 2, 3, 6, 7 होगा।

164. A process residing in main memory and ready and waiting for execution, is kept on
Main memory में स्थित, ready और execution की प्रतीक्षा कर रहा process किस queue में रखा जाता है?
(UGC NET Computer Science December 2018 (Paper-II))
A. Execution Queue
B. Job Queue
C. Wait Queue
D. Ready Queue

Correct Answer: D

Explanation (EN): Processes that are in main memory and ready to run are kept in the ready queue.

Explanation (HI): जो processes main memory में हैं और execution के लिए तैयार हैं, उन्हें ready queue में रखा जाता है।

165. For the following set of processes scheduled using FCFS policy, determine the average waiting time. Assume that the processes arrived in the order P1, P2, P3, P4.
FCFS policy से scheduled निम्न processes के लिए average waiting time ज्ञात कीजिए। मान लें कि processes P1, P2, P3, P4 के क्रम में आए हैं।
(UGC NET Computer Science December 2022)
A. 8
B. 16
C. 32
D. 48

Correct Answer: B

Explanation (EN): The waiting times are 0, 8, 23, and 33. Their average is 16.

Explanation (HI): Waiting times क्रमशः 0, 8, 23, और 33 हैं। इनका औसत 16 है।

166. Consider the following statements: S1: a small page size causes large page tables. S2: internal fragmentation is increased with small pages. S3: I/O transfers are more efficient with large pages. Which of the following is true?
निम्न statements पर विचार कीजिए: S1: छोटा page size बड़े page tables बनाता है। S2: छोटे pages के साथ internal fragmentation बढ़ती है। S3: बड़े pages के साथ I/O transfer अधिक efficient होता है। निम्न में से कौन-सा सही है?
(KVS PGT Computer Science 2017)
A. S1 is true and S3 is false
B. S1 and S2 are true
C. S2 and S3 are true
D. S1 is true and S2 is false

Correct Answer: D

Explanation (EN): Small pages cause larger page tables, but they reduce internal fragmentation. Large pages make I/O transfers more efficient.

Explanation (HI): छोटे pages बड़े page tables बनाते हैं, लेकिन internal fragmentation को कम करते हैं। बड़े pages I/O transfer को अधिक efficient बनाते हैं।

167. A computer has 32 MB memory. How many bits are needed to access any single byte in the memory?
एक computer में 32 MB memory है। Memory के किसी भी single byte को access करने के लिए कितने bits चाहिए?
(LT Grade Computer Science 2018)
A. 25
B. 16
C. 24
D. 20

Correct Answer: A

Explanation (EN): 32 MB = 2^25 bytes, so 25 bits are required to uniquely address each byte.

Explanation (HI): 32 MB = 2^25 bytes, इसलिए प्रत्येक byte को uniquely address करने के लिए 25 bits चाहिए।

168. A computer has 128 MB memory. Each word in this computer is of 8 bytes. How many bits are required to address any single word in the memory?
एक computer में 128 MB memory है। प्रत्येक word 8 bytes का है। Memory के किसी भी single word को address करने के लिए कितने bits चाहिए?
(LT Grade Computer Science 2018)
A. 27
B. 24
C. 23
D. 25

Correct Answer: B

Explanation (EN): 128 MB = 2^27 bytes. Since each word is 8 bytes = 2^3 bytes, total words = 2^24. Hence 24 bits are needed.

Explanation (HI): 128 MB = 2^27 bytes। प्रत्येक word 8 bytes = 2^3 bytes है, इसलिए कुल words = 2^24 होंगे। अतः 24 bits चाहिए।

169. Consider a disk pack with 16 surfaces, 128 tracks per surface and 256 sectors per track. 512 bytes of data are stored in a sector. The capacity of the disk pack and the number of bits required to specify a particular sector in the disk are respectively
16 surfaces, 128 tracks per surface और 256 sectors per track वाले disk pack पर विचार कीजिए। प्रत्येक sector में 512 bytes data store होता है। Disk pack की capacity और किसी particular sector को specify करने के लिए required bits क्रमशः क्या होंगे?
(LT Grade Computer Science 2018)
A. 256 MB, 19 bits
B. 256 MB, 28 bits
C. 512 MB, 20 bits
D. 64 GB, 28 bits

Correct Answer: A

Explanation (EN): Capacity = 16 × 128 × 256 × 512 bytes = 256 MB. Total sectors = 16 × 128 × 256 = 2^19, so 19 bits are needed.

Explanation (HI): Capacity = 16 × 128 × 256 × 512 bytes = 256 MB। कुल sectors = 16 × 128 × 256 = 2^19, इसलिए 19 bits चाहिए।

170. If the virtual memory size is 32 MB and physical memory size is 4 MB with a page size of 2 KB, calculate the number of frames available in physical memory.
यदि virtual memory size 32 MB, physical memory size 4 MB और page size 2 KB है, तो physical memory में available frames की संख्या ज्ञात कीजिए।
(UGC NET Computer Science December 2024)
A. 1024
B. 2048
C. 3072
D. 4096

Correct Answer: B

Explanation (EN): Number of frames = Physical memory size / Page size = 4 MB / 2 KB = 2048.

Explanation (HI): Frames की संख्या = Physical memory size / Page size = 4 MB / 2 KB = 2048।