CS476/576

Assignment #3

Due Midnight, Wednsday   Oct 27, 2004


Write a C/UNIX program with the following descriptions:

NAME

pchain - A  program that creates a chain of processes.
SYNOPSIS
pchain n
DESCRIPTION

Program output

Upon the creation of process i, the program displays the message:

Process i is created: PID=<pid1>, ParentPID=<pid2>, ChildPID=<pid3>

where <pid1>, <pid2> and <pid3> are processes ids.

Upon the termination of process i, the program displays following:

Process  i is terminated  and  the list of process is:
.....list all processes......