What will be the output of the following program? #include #include #include int value = 5; int main(){ pid_t pid; pid=fork(); if(pid==0){ printf("I am the child process.\n"); value+=15; } else if(pid>0){ wait(NULL); printf("I am the parent process, value=%d", value); exit(0); } }

Respuesta :

Answer:

The output of this program is:

I am the child process.

I am the parent process, value=5

Explanation:

The output of any given program is the generated result after a program execution.

At the end of writing any program, the output is gotten when the programmer hits the enter button to run the program.

Check attachment for output of the program.

Ver imagen kendrich
ACCESS MORE