Write a program that forks twice display the pids and ppids


Problem

1. Write a program that forks twice. Display the PIDs and PPIDs of all three processes.

2. Write a program that executes the command wc -l -c /etc/passwd using

(i) execl,

(ii) execv. What changes do you need to make if you use execlp and execvp instead?

3. Is it necessary for the parent to wait for the death of the child? What happens if it doesn't?

Request for Solution File

Ask an Expert for Answer!!
Computer Engineering: Write a program that forks twice display the pids and ppids
Reference No:- TGS02672089

Expected delivery within 24 Hours