Académique Documents
Professionnel Documents
Culture Documents
2) Write a program to run the 'ls' command using the system call
3) Write an Example program to demonstrate fork() and execl() and system calls.
4) Write a program to spawn a child process running a new executable using execvp. It should returns
the process id of
the spawned process.
5) Write a program in which the Parent process creates a child and prints its pid. The Child modifies a
variable 'x' but the change should not be visible in parent's code. Given an array with 5 elements, the
Parent should also compute the products of these elements, while the child computes the sums of these
elements.
7) Write a program to spawn a child process running a new executable using execle. It should set a
env variable and echo it