in reply to Setting up UNIX pipes and forks

Hi,

Your problem looks a lot like a homework, see Homework Alert! for why a lot of monks generally refuse to do homeworks, and where to find documentation. You can also have a look at the New Monks Info Page for even more documentation links.

Now if you could just share the code you already wrote to solve your problem, we could certainly help you fix it and improve it, but just handing you the solution would be detrimental both for you and for the other people in the class.