Hey guys I seem to be lost. I am supposed to be able to increment a count in a child inside an infinite loop, and to have the count be printed every time the parent sends a signal, which should be every 1 second. I wrote my code but I thought that after using fork, the child and parent processes run at the same time, however this is not the case so I'm not sure how to tackle this problem. Any help would be great

```
#include <stdio.h>
#include <unistd.h>
#include <signal.h>
int count = 0;//global count variable

void catch(int signal){
printf("Ouch! - I got signal %d \n", signal);
printf("count is %d\n", count);
count = 0;
}

int main(){
int pid;
int sec=0;
pid = fork();
int count1 = 0;
(void) signal(SIGALRM, catch);
if(pid==-1){
    printf("error\n");
}
else if(pid==0){//if child
    while(1){//while loop to increment count while parent to sleeping
    count = count + 1;
    }
    //pause();

    }
else{//parent
    sleep(1);//1 second pause
    raise(SIGALRM);//send alarm
    count1 = count1 + 1;
    if(count1>=5){
        return 0;
    }
    exit(0);
}
return 0;

```

}