Computers and Technology

Arid no is : 19-arid-898 Question 3: [2+2]

a)What, to whom and how many values a fork system call returns?

b)Assuming there is no syntax error, what is the output for the following C program for linux? All of you may need to put screenshot of your PC in which Terminal login must be your arid number.

int main()

{ pid_t fork_return;

fork_return = fork();

if (fork_return == 0) {

execlp("/bin/ls", "ls", NULL);

printf("Child process ID: %d\n", getpid());

exit(0);

}

else { wait (NULL);

printf("Parent process ID: %d\n", getpid());

}

return 0;

}

answer
Answers: 1

Other questions on the subject: Computers and Technology

image
Computers and Technology, 23.06.2019 06:00, sebcbal
When is a chart legend used a. all the time b. whenever you are comparing data that is the same c. whenever you are comparing multiple sets of data d. only for hand-drawn charts
Answers: 2
image
Computers and Technology, 23.06.2019 10:30, tommyaberman
Would a ps4 wired controller work on an xbox one
Answers: 1
image
Computers and Technology, 23.06.2019 19:40, Latoyajenjins1789
Use a physical stopwatch to record the length of time it takes to run the program. calculate the difference obtained by calls to the method system. currenttimemillis() just before the start of the algorithm and just after the end of the algorithm. calculate the difference obtained by calls to the method system. currenttimemillis() at the start of the program and at the end of the program so that the elapsed time includes the display of the result. use the value returned by the method system. currenttimemillis() just after the end of the algorithm as the elapsed time.
Answers: 3
image
Computers and Technology, 24.06.2019 03:30, ava1018
The footer area of a web page generally houses which website feature? terms of use web page content business name or title menu headings
Answers: 1
Do you know the correct answer?
Arid no is : 19-arid-898 Question 3: [2+2]

a)What, to whom and how many values a fork s...

Questions in other subjects:

Konu
Mathematics, 23.02.2021 22:40