1.
A critical region
Correct Answer
A. Is a piece of code which only one process executes at a time
Explanation
A critical region refers to a section of code that can only be executed by one process at a time. This is typically implemented using synchronization mechanisms such as locks or semaphores to ensure exclusive access. By allowing only one process to execute the critical region at any given time, it helps prevent race conditions and maintain data consistency.
2.
The mechanism that bring a page into memory only when it is needed is called _____________
Correct Answer
C. Demand Paging
Explanation
Demand paging is the mechanism that brings a page into memory only when it is needed. It is a memory management technique used by operating systems to optimize the use of physical memory. With demand paging, pages are loaded into memory on-demand, as they are referenced by the executing program. This helps to reduce memory wastage and improves overall system performance by only bringing in the necessary pages when required.
3.
PCB =
Correct Answer
B. Process Control Block
Explanation
The correct answer is Process Control Block. A Process Control Block (PCB) is a data structure used by the operating system to manage information about a process. It contains important details such as process ID, program counter, register information, and memory allocation. The PCB is crucial in process scheduling and context switching, as it allows the operating system to keep track of each process and its state. Therefore, the correct answer is Process Control Block.
4.
Switching the CPU to another Process requires to save the state of the old process and loading new process state is called as __________.
Correct Answer
B. Context Switch
Explanation
When the CPU switches from executing one process to another, it needs to save the state of the current process and load the state of the new process. This is known as a context switch. It involves saving the program counter, registers, and other relevant information of the current process, and then loading the saved state of the new process. This allows the CPU to seamlessly switch between different processes and maintain their individual states. Therefore, the correct answer is "Context Switch".
5.
Which directory implementation is used in most Operating System?
Correct Answer
C. Tree directory structure
Explanation
Most operating systems use a tree directory structure for organizing and managing files. This structure allows for hierarchical organization, where directories can contain subdirectories and files. This allows for easy navigation and efficient storage of files. Additionally, the tree structure allows for the implementation of access control and permissions, as well as the ability to create and manage multiple levels of directories.
6.
The Banker¿s algorithm is used
Correct Answer
A. To prevent deadlock in operating systems
Explanation
The Banker's algorithm is a resource allocation and deadlock avoidance algorithm used in operating systems. It is designed to prevent deadlock by carefully allocating resources to processes in a way that ensures safety and avoids the possibility of deadlock. By keeping track of the available resources, the maximum need of each process, and the current allocation, the Banker's algorithm can make safe decisions about granting resource requests, thus preventing deadlock from occurring.
7.
A thread
Correct Answer
A. Is a lightweight process where the context switching is low
Explanation
A thread is a lightweight process where the context switching is low. This means that threads are designed to be efficient and require less time and resources to switch between them. This allows for faster execution and better performance compared to processes. Threads share the same memory space and resources of a process, allowing for easier communication and coordination between them. Overall, threads are a way to achieve parallelism and improve the efficiency of a program by dividing it into smaller, independent units of execution.
8.
______ is a high level abstraction over Semaphore.
Correct Answer
C. Monitor
Explanation
A monitor is a high level abstraction over Semaphore because it provides a way to synchronize the access to shared resources in a concurrent program. It allows multiple threads to access the shared resources in a mutually exclusive manner, ensuring that only one thread can execute a critical section at a time. Monitors use condition variables to control the execution of threads, allowing them to wait for certain conditions to be met before proceeding. This higher level of abstraction simplifies the process of synchronization compared to using semaphores directly.
9.
A tree-structured file directory system.
Correct Answer
A. Allows easy storage and retrieval of file names
Explanation
A tree-structured file directory system allows easy storage and retrieval of file names because it organizes files in a hierarchical structure, making it easier to locate and access specific files. This structure allows for efficient navigation through directories and subdirectories, enabling users to quickly find the desired files without having to search through millions of files.
10.
Which of the following will determine your choice of systems software for your computer?
Correct Answer
D. Both 1 and 3
Explanation
The choice of systems software for your computer will be determined by both the compatibility of the applications software you want to use and whether it is compatible with your hardware.