Vidyalelo
Computer Science · Q274

Linux

Engineering and GATE · Computer Science · question 274

Q274

What is the output of this program? #include #include int main() pid_t child; child = fork(); printf("%d ",child); return 0;

A.
it will print "0"
B.
it will print the PID of the child process
C.
it will print "0" & the PID of the child process
Answer
D.
none of the mentioned

Answer: Option C

Solution

Answer: Option C
No explanation is given for this question Let's Discuss on Board