Question: Assume that create() and join() are always succeeded. How many processes and threads are created? pid_t pid; pthread_create(); pthread_join(); pid = fork(); if(pid == 0)
Assume that create() and join() are always succeeded.
How many processes and threads are created?
pid_t pid; pthread_create(); pthread_join(); pid = fork(); if(pid == 0) { } pthread_create(); pthread_join(); pid = fork(); if(pid > 0) { } pthread_create(); pthread_join(); pid = fork();
Step by Step Solution
★★★★★
3.45 Rating (152 Votes )
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
In this code snippet processes and threads are created as follows The initial pro... View full answer
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
