#include //pid_t #include //fork() #include //waitpid #include //printf... #include //exit() //gp-1.c void main(){ int pid1,pid2,pid3; pid1=fork(); if(pid1==0) execlp("/home/mumolo/proc","proc","T1",NULL); pid3=fork(); if(pid3==0) execlp("/home/mumolo/proc","proc","T3",NULL); waitpid(pid1, NULL, 0); pid2=fork(); if(pid2==0) execlp("/home/mumolo/proc","proc","T2",NULL); waitpid(pid3, NULL, 0); waitpid(pid2, NULL, 0); }