This assignment is to simulate Unix system’s multitasking function.
A particular feature of Unix system is multitasking. That is, the Unix system can “do
several things at once”. Using fork we can create new processes to perform different tasks;
using fork and exec, we can run several programs at the same time.
You are required to write a C program on Unix/Linux in which the parent process
creates three child processes, lets them run CONCURRENTLY, and waits for them to
return and prints their exit status. The three child processes are assigned different tasks.
Child one is to calculate and display the average mark of a class of ten students for a
unit. Child one is required to get the marks from the standard input (i.e. the keyboard).
Child two is to load a program called “wc” (word count) to count file1. Child two is
required to get file1 by the command line argument.
Child three is to modify file2 by first inserting “This is the updated version.” at the
beginning of this file and then replacing all the occurrences of the word “examine” by
“check”. You are required to write your OWN program for the file update. Child three is
required to get file2 by the command line argument.

Place New Order
It's Free, Fast & Safe

"Looking for a Similar Assignment? Order now and Get a Discount!