A null pointer must be passed as the last such argument. This is similar to execv , but permits you to specify the environment for the new program explicitly as the env argument. This is similar to execl , but permits you to specify the environment for the new program explicitly. The environment argument is passed following the null pointer that marks the last argv argument, and should be an array of strings in the same format as for the environ variable. This function is useful for executing system utility programs, because it looks for them in the places that the user has chosen.
Shells use it to run the commands that users type.
This function is like execl , except that it performs the same file name searching as the execvp function. See section 28.1 General Capacity Limits . Other systems may have somewhat different rules for counting. These functions normally don't return, since execution of a new program causes the currently executing program to go away completely. A value of -1 is returned in the event of a failure.