← Back to 4. Threads in Operating System

📝 Threading Issues in The fork() and exec() System Calls

📖 From Operating System • 4. Threads in Operating System • 43 questions available

Practice MCQs for Threading Issues in The fork() and exec() System Calls. Test your knowledge with carefully crafted questions across easy, medium, and hard difficulty levels.

🔄 Last updated: 2026-07-08

13
Easy Questions
20
Medium Questions
10
Hard Questions

📝 Sample Questions

Q1. What does the fork() system call do in a program?

🔹 A. Creates a new thread within the same process
🔹 B. Creates a separate duplicate process
🔹 C. Terminates the current process
🔹 D. Merges two processes into one

💡 Difficulty: easy | ✅ Correct: B

Q2. What is the effect of exec() on a multithreaded process?

🔹 A. It replaces only the code section of the process
🔹 B. It replaces the entire process including all threads
🔹 C. It creates a new thread for the new program
🔹 D. It converts all threads to processes

💡 Difficulty: medium | ✅ Correct: B

Q3. In a scenario where a program calls fork() and then exec(), what is the most efficient approach?

🔹 A. Duplicate all threads to maintain consistency
🔹 B. Duplicate only the calling thread to save resources
🔹 C. Terminate all threads before forking
🔹 D. Suspend threads during the entire operation

💡 Difficulty: hard | ✅ Correct: B

⬆️ View all questions in the quiz below

🔗 Related Topics

📝 Computer System Architecture📝 Computer System Organization📝 Computing Environments📝 Kernel Data Structures📝 Memory Management
🚀 Start Quiz 📝 Practice Mode