int main()
{
fork();
fork();
fork();
printf("Hello world!");
}
...this will print hello world 8 times...i.e . 2^n times....
but...
int main()
{
fork();
fork();
fork();
fork()
printf("Hello world!");
}
http://ideone.com/TRKTE
..but this prints only 11 times
-- and for five forks 25 times...plz tell how..or is this a prob wit
compiler???
Regards,
$iva
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/algogeeks?hl=en.