Home Operating System Predict the output of the following program code main() { fork(); fork(); fork(); printf("Hello World!"); }
Predict the output of the following program code main() { fork(); fork(); fork(); printf("Hello World!"); } E-mail
User Rating: / 0
PoorBest 
Answer:
"Hello World" will be printed 8 times.
Explanation:
2^n times where n is the number of calls to fork()
Comments
Search
Only registered users can write comments!

3.26 Copyright (C) 2008 Compojoom.com / Copyright (C) 2007 Alain Georgette / Copyright (C) 2006 Frantisek Hliva. All rights reserved."

 
 

Related links

Related Links:

Related Images

Related Links: