#include <unistd.h>
#include <stdio.h>
int main()
{
int mypid = fork(); // fork() creates a clone of the process
if (mypid == 0) {
printf("child process - %d\n", getpid());
}
else {
printf("parent process - %d\n", getpid());
}
return 0;
}
/*
run:
parent process - 22
child process - 23
*/