System Programming MCQs with Answers
Practice important System Programming MCQs with answers and explanations.
Multiple Choice Questions
Q3431: The data structure storing the resource should also store ________ corresponding to it.
- A: Mutexes
- B: Threads
- C: Processes
- D: Events
View Answer
A
Q3432: The property that ensures concurrency is correctly enforced is called ________.
- A: Invariant
- B: Variable
- C: Condition
- D: Exception
View Answer
A
Q3433: Complex decision structures for entering critical regions should be ________.
- A: Avoided
- B: Encouraged
- C: Ignored
- D: Simplified
View Answer
A
Q3434: Each critical region must have exactly ________ entry and exit points.
- A: One
- B: Two
- C: Multiple
- D: None
View Answer
A
Q3435: Mutex must be ________ on entry and ________ on exit from a critical region.
- A: Locked, unlocked
- B: Unlocked, locked
- C: Created, destroyed
- D: Deleted, created
View Answer
A
Q3436: Premature exits from critical regions such as break, return, or goto statements should be ________.
- A: Avoided
- B: Used
- C: Encouraged
- D: Implemented
View Answer
A
Q3437: Termination handlers help protect against ________ premature exits from critical regions.
- A: Unintended
- B: Intended
- C: Planned
- D: Inevitable
View Answer
A
Q3438: If critical code becomes too lengthy, it is recommended to place it in a ________.
- A: Function
- B: Loop
- C: Class
- D: Variable
View Answer
A
Q3439: WaitForSingleObject is used to ________ a mutex or synchronization object.
- A: Wait
- B: Unlock
- C: Destroy
- D: Create
View Answer
A
Q3440: A thread waiting indefinitely on a mutex without a timeout can cause a ________.
- A: Deadlock
- B: Crash
- C: Memory leak
- D: Exception
View Answer
A