wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

IOS 3 & 4 #2

Total questions: 66

Worksheet time: 33mins

Name
Class
Date
1.

True or False:
In the first fit algorithm, the memory allocator always starts scanning the free list from the beginning.

a)

True

b)

False

2.

True or False:
First fit allocates memory to the smallest available hole that can satisfy the request.

a)

True

b)

False

3.

True or False:
The first fit algorithm performs faster allocations compared to best fit.

a)

True

b)

False

4.

True or False:
In the first fit algorithm, significantly larger blocks than the requested size are split, and the remaining portion is added back to the free list.

a)

True

b)

False

5.

True or False: S
Small blocks tend to accumulate at the end of the free list in the first fit algorithm.

a)

True

b)

False

6.

True or False:
The next fit algorithm starts scanning from where it left off during the previous allocation.

a)

True

b)

False

7.

What does the first fit algorithm do when it encounters a hole large enough for the request?

a)

Allocates the last hole on the list

b)

Allocates the first hole large enough and splits it if necessary

c)

Skips the hole and searches for the best fit

d)

Allocates the smallest available hole

8.

What happens to the remaining portion of a block if it is split in the first fit algorithm?

a)

It is discarded

b)

It is merged with the next hole

c)

It is added back to the free list as a separate block

d)

It is reallocated to the same process

9.

Which algorithm starts searching the free list from the position it left off during the last allocation?

a)

Best fit

b)

First fit

c)

Next fit

d)

Worst fit

10.

What problem is associated with the first fit algorithm?

a)

It results in unused memory outside partitions

b)

Small blocks accumulate near the beginning of the free list

c)

It cannot split large blocks

d)

It always starts scanning from the end of the free list

11.

What is the main difference between first fit and next fit algorithms?

a)

Next fit scans the list in reverse order

b)

First fit starts searching from the beginning, while next fit starts from the last allocation point

c)

Next fit merges holes automatically

d)

First fit allocates the smallest block, while next fit allocates the largest block

12.

Why is the first fit algorithm generally preferred over the best fit algorithm?

a)

It leads to less fragmentation

b)

It is easier to implement

c)

It always uses the smallest available block

d)

It avoids splitting blocks

13.

True or False:
The best fit algorithm allocates the smallest available hole that is big enough to satisfy the request.

a)

True

b)

False

14.

True or False:
Best fit is faster than first fit because it requires less searching of the free list.

a)

True

b)

False

15.

Best fit can create tiny leftover holes that are too small to satisfy future memory requests.

a)

True

b)

False

16.

Both first fit and best fit algorithms suffer from external fragmentation.

a)

True

b)

False

17.

Best fit ensures that the smallest possible amount of memory is wasted after allocation.

a)

True

b)

False

18.

Best fit often leaves larger blocks of memory available for allocation than first fit.

a)

True

b)

False

19.

What is the main strategy of the best fit algorithm?

a)

Allocate the first hole encountered that is big enough

b)

Allocate the largest hole available

c)

Allocate the smallest hole that is big enough

d)

Allocate memory in fixed-sized blocks

20.

What is a primary disadvantage of the best fit algorithm?

a)

It does not search the entire list

b)

It creates tiny leftover holes that are not useful for future requests

c)

It merges free memory blocks inefficiently

d)

It never uses the smallest block available

21.

In the best fit algorithm, what is required to find the optimal hole?

a)

The free list must be ordered by memory address

b)

The entire free list must be searched

c)

The largest block must be located first

d)

The next block after the last allocation must be selected

22.

Which statement is true about the best fit algorithm?

a)

It is faster than the first fit algorithm.

b)

It minimizes external fragmentation better than other algorithms.

c)

It tends to create tiny, useless holes in memory.

d)

It avoids external fragmentation altogether.

23.

It avoids external fragmentation altogether.

a)

Best fit produces larger average holes than first fit.

b)

Best fit produces smaller average holes but more wasted memory.

c)

Best fit eliminates fragmentation entirely.

d)

Both produce the same amount of fragmentation.

24.

What is the goal of the best fit algorithm?

a)

To ensure the fastest memory allocation

b)

To maximize the use of larger memory blocks

c)

To leave the largest remaining allocable blocks free

d)

To prevent fragmentation completely

25.

True or False:
The worst fit algorithm allocates memory from the smallest available hole.

a)

True

b)

False

26.

True or False:
Worst fit aims to leave the largest leftover hole after allocation.

a)

True

b)

False

27.

True or False:
In the worst fit algorithm, the largest available block is chosen to fulfill a process's memory request.

a)

True

b)

False

28.

True or False:
The worst fit algorithm operates similarly to the best fit algorithm.

a)

True

b)

False

29.

True or False:
Worst fit creates the largest remaining block to increase the likelihood of future allocations.

a)

True

b)

False

30.

What does the worst fit algorithm do?

a)

Allocates the smallest hole available

b)

Allocates the first hole available

c)

Allocates the largest hole available

d)

Allocates the hole closest to the requested size

31.

What is the primary goal of the worst fit algorithm?

a)

To minimize fragmentation

b)

To create the smallest leftover hole

c)

To create the largest leftover hole for future allocations

d)

To reduce allocation time

32.

Which of the following is true about the worst fit algorithm?

a)

It searches for the smallest available block.

b)

It creates large leftover blocks to increase the likelihood of future allocations.

c)

It splits large blocks into smaller pieces for efficiency.

d)

It operates similarly to the first fit algorithm.

33.

What would the worst fit algorithm do if a process requests 12KB and the available memory blocks are 6KB, 14KB, 19KB, and 13KB?

a)

Allocate 12KB of the 13KB block

b)

Allocate 12KB of the 14KB block

c)

Allocate 12KB of the 19KB block

d)

Allocate 12KB of the 6KB block

34.

How does the worst fit algorithm differ from the best fit algorithm?

a)

Worst fit allocates the largest hole, while best fit allocates the smallest hole that satisfies the request.

b)

Worst fit allocates the smallest hole, while best fit allocates the largest hole that satisfies the request.

c)

Worst fit and best fit allocate the same block in every scenario.

d)

Worst fit skips searching for blocks entirely.

35.

True or False:
Swapping is a memory management technique used to increase the number of processes sharing the CPU.

a)

True

b)

False

36.

What is a potential disadvantage of the worst fit algorithm?

a)

It may increase the number of small leftover holes, leading to fragmentation.

b)

It always results in longer allocation times compared to best fit.

c)

It prioritizes smaller processes over larger processes.

d)

It does not utilize memory efficiently for large requests.

37.

True or False:
Swap Out is the process of moving a process from secondary memory to main memory.

a)

True

b)

False

38.

True or False:
Swapping can involve copying a blocked or waiting job to disk if the disk is available.

a)

True

b)

False

39.

True or False:
When a job is blocked, swapping is the only available method for managing memory.

a)

True

b)

False

40.

What is the purpose of swapping in memory management?

a)

To terminate processes when memory is full

b)

To remove processes from secondary memory permanently

c)

To increase the number of processes sharing the CPU

d)

To avoid using secondary memory entirely

41.

What happens during a Swap Out operation?

a)

A process is executed in secondary memory.

b)

A process is moved from secondary memory to main memory.

c)

A process's data and code are copied to disk, releasing main memory.

d)

A process is permanently deleted from the system.

42.

Why might a job be swapped out of memory?

a)

To execute it directly from disk

b)

To free up main memory for other jobs

c)

To avoid the need for short-term scheduling

d)

To terminate the job temporarily

43.

How does the system bring the required page into physical memory during a page fault?

a)

Through a page swap operation

b)

By rearranging existing frames in memory

c)

By converting logical addresses into physical addresses

d)

By terminating the current process

44.

How does swapping impact the system's level of multiprogramming?

a)

It decreases the multiprogramming level by freeing memory.

b)

It has no effect on the multiprogramming level.

c)

It eliminates the need for multiprogramming.

d)

It increases the multiprogramming level by allowing more jobs in memory.

45.

True or False:
Virtual memory allows processes to run even if they are not fully loaded into main memory.

a)

True

b)

False

46.

True or False:
Logical addresses are actual physical locations in RAM.

a)

True

b)

False

47.

What is the purpose of paging in memory management?

a)

To allocate contiguous blocks of physical memory

b)

To allow the physical memory of a process to be non-contiguous

c)

To store data permanently in virtual storage

d)

To replace segmentation in memory management

48.

Which of the following is not a feature of paging?

a)

It requires the use of a page table.

b)

It leads to external fragmentation.

c)

It uses fixed-sized blocks for memory allocation.

d)

It allows processes to run with non-contiguous memory allocation.

49.

True or False:
The Memory Management Unit (MMU) is responsible for translating logical addresses to physical addresses.

a)

True

b)

False

50.

True or False:
Virtual memory systems can support a virtual address space smaller than the physical address space.

a)

True

b)

False

51.

True or False:
The Least Used algorithm assumes that a page not recently accessed will probably not be used soon.

a)

True

b)

False

52.

True or False:
During a page swap, the CPU directly transfers the required page from auxiliary storage to the physical memory.

a)

True

b)

False

53.

What is the size of a standard page or frame in most paging systems?

a)

512 bytes

b)

1 KB

c)

4 KB

d)

16 KB

54.

What is a frame in paging?

a)

A block of virtual storage

b)

A block of auxiliary storage

c)

A block of physical RAM

d)

A data structure for address translation

55.

What is virtual memory?

a)

A memory storage device in the CPU

b)

A technique to provide larger memory space than physically available

c)

A method to directly access RAM without mapping

d)

A physical partitioning of memory into smaller blocks

56.

What algorithm is typically used to select a page for swapping out?

a)

First-In, First-Out

b)

Least Recently Used

c)

Most Frequently Used

d)

Random Replacement

57.

What does the MMU (Memory Management Unit) do?

a)

Allocates physical addresses directly to programs

b)

Maps logical addresses to physical addresses during runtime

c)

Manages secondary memory exclusively

d)

Converts RAM addresses to disk addresses

58.

What is the difference between logical and physical addresses?

a)

Logical addresses are abstract, and physical addresses are in RAM.

b)

Logical addresses are in RAM, and physical addresses are in disk.

c)

Logical addresses are generated by MMU, and physical addresses by the CPU.

d)

Logical addresses store physical data while physical addresses store virtual data

59.

True or False:
In paging, all the pages of a program must be in central storage simultaneously for the program to execute.

a)

True

b)

False

60.

True or False:
Paging is transparent to the user and occurs automatically during program execution.

a)

True

b)

False

61.

What is one key advantage of virtual memory?

a)

It reduces the need for secondary storage.

b)

It eliminates the need for the MMU.

c)

Programs can be larger than the physical memory available.

d)

It avoids runtime mapping of addresses.

62.

True or False:
Paging eliminates external fragmentation.

a)

True

b)

False

63.

A page is a fixed-size block of physical RAM, while a frame is a fixed-size block of virtual memory.

a)

True

b)

False

64.

What happens when the CPU encounters a page fault?

a)

It continues execution without interruption

b)

The MMU raises an exception, and the OS loads the required page

c)

The CPU swaps out the current process immediately

d)

The physical memory is reset

65.

The operating system uses a page table to store mappings between virtual and physical addresses.

a)

True

b)

False

66.

What does the page table store?

a)

The list of available frames in RAM

b)

The mapping between virtual and physical addresses

c)

The priority of processes in execution

d)

The pages that are currently swapped out