ישן

Calculate number of times hello is printed: #include <stdio.h> #include <sys/types.h> int main() { fork(); fork(); fork(); printf("hello\n"); return 0; }

done
The number of times ‘hello’ is printed is equal to number of process created. Total Number of Processes = 2^n, where n is number of fork system calls. So here n = 3, 2^3 = 8
by stav shlomovich
נערך  Jul 20 '20 - 13:17 stav shlomovich
visibility   חדש

* השאלה נוספה בתאריך: 20-07-2020