wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

MCQ Exam - CO3

Total questions: 100

Worksheet time: 50mins

Name
Class
Date
1.

A process of 120 KB is loaded into a 150 KB partition. How much internal fragmentation occurs?

a)

20 KB

b)

30 KB

c)

10 KB

d)

None

2.

Convert 512 KB to bytes.

a)

512000

b)

524288

c)

500000

d)

102400

3.

Identify the external fragmentation if holes are: 100 KB, 300 KB, 150 KB and process = 200 KB

a)

150 KB

b)

100 KB

c)

50 KB

d)

450 KB

4.

Explain why Best Fit leads to more fragmentation than First Fit with example: 200 KB process

a)

Fits smaller holes

b)

Uses biggest hole

c)

No fragmentation

d)

Always optimal

5.

Choose the most suitable hole for 125 KB process among using Best Fit

a)

130 KB

b)

140 KB

c)

200 KB

d)

None

6.

Apply First Fit for a 320 KB process on holes: 300 KB, 400 KB, 350 KB

a)

350 KB

b)

300 KB

c)

400 KB

d)

None

7.

Determine internal fragmentation when 3 processes use partitions of 256 KB, with sizes 240 KB each

a)

16 KB

b)

48 KB

c)

36 KB

d)

32 KB

8.

Memory allocation strategy causing least fragmentation

a)

First Fit

b)

Best Fit

c)

Worst Fit

d)

Random Fit

9.

Memory allocation technique that wastes more memory but faster

a)

Best Fit

b)

Worst Fit

c)

First Fit

d)

Next Fit

10.

Component resolving external symbols at runtime in dynamic linking

a)

Loader

b)

Compiler

c)

Dynamic Linker

d)

Assembler

11.

Bytes allocated by dynamic memory allocator requesting 1500 bytes in 512-byte chunks

a)

1500

b)

2048

c)

1536

d)

1024

12.

Absolute address if linker assigns 3000 and relative address is 250

a)

250

b)

2750

c)

3250

d)

3000

13.

Initial memory required if program size is 800 KB with 300 KB dynamic linking

a)

300 KB

b)

500 KB

c)

800 KB

d)

100 KB

14.

Number of undefined symbols detected by linker given object files

a)

0

b)

1

c)

2

d)

3

15.

In an operating system, memory management is essential to ensure processes execute efficiently. One common method is paging, which divides memory into fixed-size blocks. This allows non-contiguous memory allocation and simplifies memory allocation. Which of the following is correct?

a)

It allows memory allocation based on process size

b)

It helps in allocating contiguous memory for each process

c)

It breaks memory into fixed-size blocks to avoid external fragmentation

d)

It increases internal fragmentation significantly

16.

When a process is loaded into memory using paging, its logical address space is divided into pages, and the physical memory is divided into frames. The page table is used for address translation. Which of the following is the correct mapping mechanism?

a)

Frame to page via TLB

b)

Logical to physical address using page table

c)

Physical to logical mapping using segments

d)

Frame to segment using base and limit

17.

Paging can lead to internal fragmentation, especially when process sizes are not multiples of page sizes. Suppose a system uses a 4KB page size and a process requires 18KB of memory. What is the internal fragmentation in this case?

a)

2KB

b)

4KB

c)

6KB

d)

8KB

18.

Segmentation differs from paging by allowing memory to be divided based on logical divisions such as functions, arrays, and data structures. This enables better protection and sharing. What is the major disadvantage of segmentation when compared to paging?

a)

Leads to internal fragmentation

b)

Increases system security

c)

Causes external fragmentation

d)

Does not support multiprogramming

19.

In segmentation, a logical address consists of a segment number and an offset. If the offset is larger than the segment limit, what kind of fault does the system generate, and why?

a)

Page fault due to invalid offset

b)

Memory overflow due to large limit

c)

Segment fault due to invalid offset

d)

No error occurs; memory wraps around

20.

Segmentation provides better support for protection and sharing compared to paging. Each segment can have separate permissions and sharing attributes. Which of the following scenarios best demonstrates this advantage of segmentation?

a)

A. A program accessing its stack segment

b)

B. Multiple processes sharing a code segment read-only

c)

C. A process performing I/O operations

d)

D. A program using malloc for dynamic memory

21.

In segmentation with paging, the logical address is divided into three parts: segment number, page number, and offset. This hybrid scheme combines the benefits of both methods. What is the primary motivation behind this approach?

a)

A. Simplify address translation

b)

B. Eliminate both internal and external fragmentation

c)

C. Provide efficient memory usage with better protection

d)

D. Increase context switching time

22.

Virtual memory allows address translation between a process's virtual address and the actual physical memory address. For this translation to work efficiently, the virtual address is divided into two components, one used to find the page and the other the offset. What are these two components?

a)

Segment & offset

b)

Page number & offset

c)

Frame number & segment

d)

Block & segment

23.

When a process accesses a page that is not currently in main memory, a special event occurs where the operating system must retrieve the missing page from the disk and load it into RAM. This event introduces overhead and delays execution. What is this event called?

a)

RAM reload

b)

Cache miss

c)

Page fault

d)

Memory interrupt

24.

Suppose a 32-bit system uses a 4KB page size for managing memory. Since each page must be uniquely addressed, the total number of virtual pages that the system can manage is directly tied to the number of addressable bits and the page size. What is the total number of virtual pages?

a)

2102^10

b)

2122^12

c)

2202^20

d)

2222^22

25.

During the execution of a program, if the data or code that a CPU needs to access is not found in the physical memory, the CPU triggers a mechanism to bring that data into RAM from the secondary storage. This leads to additional delays and memory:

a)

Process starvation

b)

Context switch

c)

Page fault

d)

Memory leak

26.

Lazy swapping or "demand paging" brings a page into memory only when:

a)

The process is first loaded into memory.

b)

The operating system anticipates its need.

c)

An attempt is made to access a location on that page.

d)

Periodically, based on a timer.

27.

Which page replacement algorithm selects the page that has not been used for the longest period?

a)

FIFO (First-In, First-Out)

b)

LRU (Least Recently Used)

c)

Optimal

d)

LFU (Least Frequently Used)

28.

What is the primary advantage of using a Translation Lookaside Buffer (TLB) in a paged memory system?

a)

To increase the capacity of physical memory

b)

To reduce the page fault rate

c)

To speed up the translation of logical addresses to physical addresses

d)

To store the entire page table

29.

When a page fault occurs, which of the following actions is NOT typically performed by the operating system?

a)

Choose a victim frame if all frames are full.

b)

Write the victim page to disk if it is dirty.

c)

Load the desired page from disk into the chosen frame.

d)

Immediately terminate the faulting process.

30.

A system encounters a page fault, which triggers the operating system to bring the missing page from disk into RAM. If RAM is full, the OS uses a replacement algorithm to choose a page to be removed. What happens if the replaced page was modified?

a)

The OS deletes it

b)

The page is written back to disk

c)

The page is ignored

d)

A segmentation fault occurs

31.

Consider a system with 3 page frames. For the page reference string 1, 2, 3, 4, 1, 2, 5, 1, 2, 3, 4, 5, how many page faults occur with the LRU (Least Recently Used) page replacement algorithm?

a)

7

b)

8

c)

9

d)

10

32.

In a virtual memory system, what condition triggers the need for a page replacement?

a)

High CPU utilization

b)

Lack of disk space

c)

Page fault with no free frame available

d)

Timer interrupt

33.

Calculate total memory wasted by internal fragmentation for 4 partitions of 512 KB

a)

120 KB

b)

64 KB

c)

128 KB

d)

96 KB

34.

Analyze the difference in allocation success rate between First Fit and Worst Fit (200 KB process)

a)

Same

b)

First Fit better

c)

Worst Fit better

d)

None

35.

Compare swap time of 3 processes at 40 ms each with and without parallel swapping

a)

120 ms vs 40 ms

b)

60 ms vs 120 ms

c)

Same

d)

30 ms vs 90 ms

36.

Design an efficient memory allocation sequence for processes: 180 KB, 300 KB, 400 KB using Best Fit

a)

180, 300, 400

b)

400, 300, 180

c)

300, 400, 180

d)

180, 400, 300

37.

Recommend an allocation strategy for minimizing fragmentation

a)

First Fit

b)

Worst Fit

c)

Best Fit

d)

Paging

38.

Estimate total fragmentation when process sizes: 480 KB, 500 KB, 490 KB use 512 KB partitions

a)

A) 48 KB

b)

B) 64 KB

c)

C) 54 KB

d)

D) 60 KB

39.

Number of 512-byte blocks allocated by malloc call of 4096 bytes

a)

A) 4

b)

B) 8

c)

C) 6

d)

D) 12

40.

Number of physical memory copies of shared library used by 5 processes

a)

1

b)

2

c)

Depends on OS

d)

5

41.

Allocation strategy resulting in largest leftover hole

a)

First Fit

b)

Best Fit

c)

Worst Fit

d)

Next Fit

42.

Allocation method failing if 700 KB requested but only 600 KB contiguous

a)

Segmentation

b)

Paging

c)

Demand Paging

d)

Contiguous Allocation

43.

A system with segmentation and paging uses a segment table and a page table for memory management. If a process accesses a logical address, how many memory accesses are required to translate it assuming no TLB is used?

a)

One

b)

Two

c)

Three

d)

Four

44.

Consider a process with three segments: code, stack, and data. Each segment is divided into pages in a segmented-paging system. Which table structures are required for correct address translation?

a)

Only one global page table

b)

A single segment table for all processes

c)

A segment table with individual page tables for each segment

d)

No tables required

45.

A 32-bit system using segmentation with paging has 4 segments per process and each segment has its own page table. If each page size is 4KB and each segment supports up to 1MB, what is the maximum number of pages per segment?

a)

A) 128

b)

B) 256

c)

C) 512

d)

D) 1024

46.

In paging, all frames in physical memory are of the same size, which matches the page size of processes. Suppose a process requires 10 pages, but physical memory has only 6 free frames. What is the result if demand paging is enabled?

a)

Process runs immediately using all frames

b)

OS swaps all pages before execution

c)

Process partially loads into memory and executes with page faults

d)

Execution is denied

47.

When paging is used, address translation becomes crucial. Suppose a virtual address needs to be translated into a physical address. What components are needed and what is the process involved in this translation?

a)

Base register and segment offset

b)

Page number and offset using page table

c)

Frame number and segment number using TLB

d)

Logical block number and physical block

48.

Segmentation can simplify memory protection. Suppose a segment is marked as read-only in a program. What happens if a write operation is attempted on this segment, and why?

a)

Operation proceeds with a warning

b)

Operation is ignored silently

c)

Segmentation fault occurs

d)

System restarts

49.

Consider a virtual memory system that uses demand paging. The system only loads pages when they are required. Suppose a program accesses a sequence of instructions located across different pages. How does demand paging impact the initial performance?

a)

Enhances performance by preloading pages

b)

Reduces CPU speed permanently

c)

Causes initial delays due to page faults

d)

Allows faster memory mapping

50.

The working set model is used in memory management to predict which pages a process will need in the near future. It considers a window of recent page references. Which of the following best defines the working set?

a)

All pages in the disk

b)

Set of recently used pages in a fixed time

c)

All pages in RAM

d)

Random pages accessed previously

51.

Suppose a system is experiencing frequent page faults, causing excessive disk I/O and degraded performance. The system administrator decides to increase the size of the main memory. How does this change affect the virtual memory behavior?

a)

Increases page faults

b)

Reduces page faults

c)

Increases context switching

d)

Reduces hit ratio

52.

In a virtual memory system, each process has its own page table, which maps virtual pages to physical frames. If the page table becomes too large, it can slow down the system. What structure can the OS use to handle this problem efficiently?

a)

Inverted page table

b)

Hash table

c)

Direct table

d)

Circular queue

53.

A virtual memory system uses both segmentation and paging. The virtual address includes a segment number, page number, and offset. What is the benefit of combining both techniques in a single system?

a)

Increases fragmentation

b)

Reduces protection

c)

Enables flexible memory management

d)

Disables multiprogramming

54.

In memory management, the working set model defines a process's working set as the group of pages it is currently using. This model aims to reduce page faults by keeping frequently accessed pages readily available in memory. What is the working set?

a)

The total virtual memory used by all processes

b)

The set of pages actively used by the process during a time window

c)

The swap memory size

d)

The main memory size

55.

If a page required by a running process is not found in main memory, a page fault occurs. The system must then retrieve the page from disk storage, load it into memory, and possibly replace another page to make room for it.

a)

A segmentation fault occurs

b)

A page hit happens

c)

A page fault is triggered

d)

The process is terminated

56.

Thrashing is a condition in which an operating system becomes overwhelmed by excessive paging activity. It arises when processes collectively exceed available memory, leading to inefficient CPU utilization and decreased system throughput.

a)

High CPU utilization

b)

Low I/O requests

c)

Excessive page faults

d)

Lack of CPU scheduling

57.

The working set model identifies the subset of memory pages a process accesses during a specific timeframe. Maintaining these pages in memory is crucial to reduce the number of page faults and ensure efficient execution.

a)

The total virtual memory used by all processes

b)

The set of pages actively used by the process during a time window

c)

The swap memory size

d)

The main memory size

58.

The Hard Disk Drive (HDD) operates using a spinning platter, on which data is stored magnetically. This rotation enables the read/write heads to access different parts of the disk for data operations.

a)

SSD

b)

RAM

c)

Magnetic disk

d)

Cache memory

59.

A process of 120 KB is loaded into a 150 KB partition. How much internal fragmentation occurs?

a)

20 KB

b)

30 KB

c)

10 KB

d)

None

60.

Choose the most suitable hole for 125 KB process among using Best Fit

a)

130 KB

b)

140 KB

c)

200 KB

d)

None

61.

Apply First Fit for a 320 KB process on holes: 300 KB, 350 KB, 400 KB

a)

350 KB

b)

300 KB

c)

400 KB

d)

None

62.

Determine internal fragmentation when 3 processes use partitions of 256 KB, with sizes 240 KB each

a)

16 KB

b)

48 KB

c)

36 KB

d)

32 KB

63.

In contiguous memory allocation, external fragmentation occurs when total free memory exists but is not contiguous. Which allocation technique helps reduce external fragmentation without relocating processes?

a)

Segmentation

b)

Paging

c)

Static partitioning

d)

Stack allocation

64.

In a virtual memory system, if the page table is too large to fit in memory, which mechanism is most appropriate to reduce memory access overhead during address translation?

a)

TLB (Translation Lookaside Buffer)

b)

Associative Cache

c)

Segmentation

d)

Stack Pointer

65.

In a demand paging system, increasing the degree of multiprogramming may lead to higher page fault rates. Which phenomenon best explains this behavior?

a)

Fragmentation

b)

Thrashing

c)

Deadlock

d)

Segmentation Fault

66.

A process uses 10 pages out of its 100-page virtual address space frequently. The rest are rarely used. Which virtual memory technique best reduces memory usage while maintaining performance?

a)

FIFO Page Replacement

b)

Demand Paging

c)

Contiguous Allocation

d)

Compaction

67.

In a virtual memory system, if a process’s page fault rate increases significantly with increased CPU utilization, which phenomenon is occurring?

a)

Deadlock

b)

Fragmentation

c)

Thrashing

d)

Starvation

68.

A process accesses pages in the order: 0, 4, 1, 4, 2, 3, 4, 2, 3, 4, 2, 1, using a memory with 3 frames and FIFO replacement. How many page faults occur?

a)

7

b)

6

c)

8

d)

5

69.

A system uses virtual memory with a page size of 4 KB. If the logical address space is 32 bits and the physical memory is 4 GB, how many bits are used for the page number in the virtual address?

a)

10 bits

b)

20 bits

c)

22 bits

d)

24 bits

70.

A logical address is divided as follows: 3 bits for segment number, 5 bits for page number, and 8 bits for offset. What is the maximum size of the virtual address space?

a)

4 KB

b)

8 KB

c)

32 KB

d)

64 KB

71.

A process is divided into 4 segments and each segment into pages of size 1 KB. Logical address is 16 bits, segment field is 2 bits, page field is 6 bits. What is the size of the offset field?

a)

4 KB

b)

8 KB

c)

32 KB

d)

64 KB

72.

A process is divided into 4 segments and each segment into pages of size 1 KB. Logical address is 16 bits, segment field is 2 bits, page field is 6 bits. What is the size of the offset field?

a)

8 bits

b)

6 bits

c)

10 bits

d)

4 bits

73.

In a segmentation system, a process has the following segment table: Segment 0 – base=1000, limit=500; Segment 1 – base=2000, limit=400. What is the physical address for logical address (1, 300)?

a)

A) 2300

b)

B) 1300

c)

C) 1700

d)

D) 2400

74.

In a contiguous memory allocation system, assume the memory has holes of sizes 100 KB, 500 KB, 200 KB, 300 KB, and 600 KB (in order). A process requests 212 KB of memory. Using the Best Fit strategy, which block is allocated?

a)

500 KB

b)

600 KB

c)

300 KB

d)

200 KB

75.

A system allows swapping of processes to secondary memory. A process of size 200 MB is swapped out and a new process of size 150 MB is loaded. After execution, the original process is swapped back. If no compaction is used, what is the possible cause of failure in loading the original process?

a)

Stack overflow

b)

External fragmentation

c)

Invalid page fault

d)

Memory underflow

76.

Consider a system with fixed-size partitions: 100 KB, 250 KB, 400 KB. A process requires 260 KB. Which of the following best explains why the process cannot be allocated despite total available memory being 750 KB?

a)

A) Internal fragmentation

b)

B) Stack overflow

c)

C) External fragmentation

d)

D) Partition size limitation

77.

Consider a memory allocation scenario with hole sizes 100 KB, 400 KB, 200 KB, 500 KB, and 300 KB. A process requests 220 KB of memory. Using the First Fit allocation strategy, which hole will be selected for allocation?

a)

400 KB

b)

500 KB

c)

200 KB

d)

300 KB

78.

A system has memory holes of sizes 350 KB, 200 KB, 700 KB, 250 KB, and 100 KB. A process requires 310 KB of space. Using the Worst Fit strategy for contiguous memory allocation, which hole will be selected?

a)

350 KB

b)

700 KB

c)

250 KB

d)

200 KB

79.

A system uses First Fit memory allocation. Given holes of 100 KB, 500 KB, and 200 KB in sequence, and three incoming processes requiring 90 KB, 110 KB, and 200 KB respectively, how many processes can be allocated memory without compaction?

a)

One

b)

Two

c)

Three

d)

None

80.

Swapping involves moving processes between main memory and secondary storage. Which condition may lead to thrashing when frequent swapping occurs under high degree of multiprogramming?

a)

Processes remain in blocked state

b)

CPU executes I/O instructions only

c)

Page fault rate becomes low

d)

Most processes spend more time in swapping than execution

81.

Consider a system with page size 1 KB and physical memory size of 32 KB. If the logical address space is 8 pages, how many bits are needed for the physical address?

a)

10 bits

b)

12 bits

c)

15 bits

d)

13 bits

82.

A virtual memory system with demand paging has a page fault rate of 0.1 and memory access time of 100 ns. Page fault service time is 10 ms. What is the effective memory access time (EMAT)?

a)

1.1 ms

b)

1.01 ms

c)

100 ns

d)

100 ms

83.

Consider a system with a 32-bit logical address space and a page size of 1 KB. If the system uses a two-level paging scheme where the outer page table has 256 entries, what is the number of bits used for the outer page table index?

a)

A. 8

b)

B. 10

c)

C. 12

d)

D. 16

84.

A system uses virtual memory with a 4-level hierarchical page table. If each page table entry takes 4 bytes and page size is 4 KB, what is the total size of the page tables for mapping a 48-bit virtual address space?

a)

4 MB

b)

64 MB

c)

128 MB

d)

256 MB

85.

Given a page reference string: 1, 2, 3, 4, 1, 2, 5, 1, 2, 3, 4, 5, and 3 frames. Using Optimal page replacement, how many page faults occur?

a)

9

b)

10

c)

7

d)

8

86.

For a memory with 4 frames, and a reference string: 7, 0, 1, 2, 0, 3, 0, 4, 2, 3. Using Least Recently Used (LRU) page replacement, determine the number of page faults.

a)

6

b)

7

c)

8

d)

9

87.

A system uses LRU page replacement. Given page reference string 1, 2, 3, 2, 4, 1, 5, 2 and 3 frames, how many page faults occur?

a)

6

b)

7

c)

8

d)

5

88.

A system has a working set window of 4 pages and the process refers to the page sequence 1, 2, 3, 4, 5, 6, 2, 3, 4, 5. What is the working set size after the 10th reference?

a)

4

b)

5

c)

6

d)

3

89.

In a demand paging system, the average memory access time is 150 ns. If the page fault rate is 0.001 and the service time for a page fault is 8 ms, calculate the effective memory access time.

a)

8.15 μs

b)

158 ns

c)

8.1 μs

d)

150 ns

90.

Consider a virtual memory system with a FIFO page replacement policy. For an arbitrary page access pattern, increasing the number of page frames in the main memory will

a)

Always decrease the number of page faults

b)

Always increase the number of page faults

c)

Sometimes increase the number of page faults

d)

Never affect the number of page faults

91.

A process refers to 5 pages, A, B, C, D, E in the order: A, B, C, D, A, B, E, A, B, C, D, E. If the page replacement algorithm is FIFO, the number of page transfers with an empty internal store of 3 frames is?

a)

8

b)

10

c)

9

d)

7

92.

A program has three modules with sizes 4 KB, 6 KB, and 8 KB respectively. The dynamic linker uses lazy binding and loads only necessary modules during execution. If only the first two modules are used during a particular run, what is the total memory occupied by the loaded modules?

a)

10 KB

b)

18 KB

c)

8 KB

d)

20 KB

93.

If a logical address consists of a 4-bit segment number, 3-bit page number, and 10-bit offset, what is the total logical address size in bits and the total logical address space in KB?

a)

17 bits, 128 KB

b)

17 bits, 256 KB

c)

17 bits, 64 KB

d)

20 bits, 256 KB

94.

A system with 32-bit logical address space uses demand paging with a page size of 4 KB. If the memory contains 256 frames, how many bits are used for the frame number in the physical address?

a)

8 bits

b)

10 bits

c)

12 bits

d)

16 bits

95.

Calculate the effective memory access time if the memory access time is 100 ns, page fault service time is 10 ms, and page fault rate is 0.001.

a)

109,900 ns

b)

10,000 ns

c)

199 ns

d)

10,100 ns

96.

A system uses LRU page replacement. The reference string is: 1, 2, 3, 4, 2, 1, 5, 6, 2, 1, 2, 3, 7. If the number of frames is 3, how many page faults will occur?

a)

11

b)

10

c)

9

d)

8

97.

A process has a working set size of 4 pages and currently allocated 3 frames. If the page-fault frequency is high, what should be the minimum number of frames allocated to reduce thrashing?

a)

2

b)

3

c)

4

d)

5

98.

A disk has 5000 cylinders. The request queue has requests for cylinders 40, 10, 4500, 4000, 30, 1000. If the disk arm is currently at cylinder 50, calculate the total head movement using the SCAN algorithm moving towards higher cylinder numbers.

a)

4990 cylinders

b)

4960 cylinders

c)

5030 cylinders

d)

5100 cylinders

99.

A program has 5 dynamically linked libraries each of 12 KB. If only 3 libraries are loaded dynamically at runtime, what is the total dynamic memory used for libraries?

a)

36 KB

b)

60 KB

c)

48 KB

d)

72 KB

100.

A dynamic storage system uses a buddy system. The total free memory is 1024 KB. If a request of 140 KB arrives, what is the size of the allocated block?

a)

128 KB

b)

256 KB

c)

512 KB

d)

1024 KB