return to UNIX

Write a program creating n "child" processes, each subprocess starts with specified integer parameter k. Child process sends it's "k" parameter with SIGRTMIN signal to parent process and sleeps for approximately k sec. Subprocess repeats this action in a loop. Parent process should print received integers immediately upon signal arrival. In the same time parent process in a loop prints "*" exactly every 1 second.

Program can be terminated at any moment with SIGINT (C-c).

Program takes n integer "k" parameters where k > 0(non number parameters can be treated as 1), one parameter for one child.

This task will be graded by Marcin Borkowski, please submit your solutions to /home2/samba/borkowskim/unix/ folder.

Additional Remarks:

return to UNIX