#include
#include
#include
int main(void)
{
if (fork() > 0)
/* Forces parent to wait for child
* to force scheduling order */
wait(NULL);
printf(“My PID is %d\n”, getpid());
printf(“My parent’s PID is %d\n”, getppid());
return 0;
}