What is the output of this progarm?
#include<stdio.h>
#include<unistd.h>
int main()
{
execl("/bin/ls","ls",NULL);
return 0;
}
#include<stdio.h>
#include<unistd.h>
int main()
{
execl("/bin/ls","ls",NULL);
return 0;
}A. the program will give an compilation error
B. the program will give segmentation fault
C. the program will execute just like "ls" command
D. none of the mentioned
Answer: Option C

Join The Discussion