Question:

In the context of process creation, arrange the following statements in sequential order of their occurrence: A. One of the two processes typically uses the exec() system call to replace the process's memory space with a new program.
B. A new process is created by the fork() system call.
C. The parent can then create more children; or, can issue a wait() system call to move itself off the ready queue.
D. The exec() system call loads a binary file into memory (destroying the memory image of the program containing the exec() system call) and starts its execution.
Choose the correct answer from the options given below:

Show Hint

In process creation, the **fork()** system call creates a child process, and **exec()** replaces the memory space of the child process with a new program.
Updated On: Sep 25, 2025
  • A, B, C, D
  • A, C, B, D
  • B, A, D, C
  • C, B, D, A
Hide Solution
collegedunia
Verified By Collegedunia

The Correct Option is C

Solution and Explanation


Step 1: Understand the process creation sequence.
- **B**: The process creation starts with the **fork()** system call, which creates a new child process. - **A**: After the process is created, the **exec()** system call is used by the child process to replace its memory space with a new program. - **D**: The **exec()** system call loads a new binary file into memory and starts execution. - **C**: The parent process can then create more children or call the **wait()** system call to wait for the child process to finish execution.

Step 2: Conclusion.
Thus, the correct order is **B, A, D, C**.

Was this answer helpful?
0
0