What is output of the following program?

int main() {
fork();
fork();
fork();
if (wait(0) == -1)
printf("leaf childn");
}

a) "leaf child" will be printed 1 times
b) "leaf child" will be printed 3 times
c) "leaf child" will be printed 4 times
d) "leaf child" will be printed 8 times

Submitted by: Murtaza
c) "leaf child" will be printed 4 times
Submitted by: Murtaza

Read Online Linux OS Management Job Interview Questions And Answers