What is the output of the following program

#include<stdio.h>
main()
{
int i=0;
fork();
printf("%d",i++);
fork();
printf("%d",i++);
fork();
wait();
}

Answer Posted / vignesh1988i

01 finally i will have 2

Is This Answer Correct ?    4 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can you explain what keyboard debouncing is, and where and why we us it? please give some examples

1648


Not all reserved words are written in lowercase. TRUE or FALSE?

719


Is stack a keyword in c?

632


Why are some ANSI/ISO Standard library routines showing up as undefined, even though I've got an ANSI compiler?

661


Do you know what are the properties of union in c?

577






What are external variables in c?

540


Why enum is used in c?

518


Explain what is the advantage of a random access file?

657


code for find determinent of amatrix

1511


What is pivot in c?

563


Function calling procedures? and their differences? Why should one go for Call by Reference?

629


In a byte, what is the maximum decimal number that you can accommodate?

624


What is the use of getchar functions?

672


Explain how can you tell whether a program was compiled using c versus c++?

571


Tell us bitwise shift operators?

592