This very simple example of exec() system call. Here, I am trying to call execlp() twice. But, I am not getting excepted output. It shows output only f
exec()
execlp()
execlp () replaces the process that called it by the process which was called.
execlp ()
From this link:
"The exec() family of functions replaces the current process image with a new process image."
To retain both the processes, use fork().
fork().