#include #include int main() { int p; printf("%d started\n", getpid()); fflush(stdout); p = fork(); printf("%d after first fork p = %d\n", getpid(), p); fflush(stdout); p = fork(); printf("%d after second fork p = %d\n", getpid(), p); fflush(stdout); p = fork(); printf("%d after third fork p = %d\n", getpid(), p); fflush(stdout); printf("%d finished\n", getpid()); fflush(stdout); }