for(i=1;i>0;i++);
printf("i=%d",i);
what will be the answer????

Answer Posted / ankit shekhavat

after for lop,there is a semicolon.it means loop terminate
here..condition inside the loop will always true.so it will
be an infinite loop..nothing will be printed on the screen.
for next statement there will be printed any garbage value...

Is This Answer Correct ?    7 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to create struct variables?

595


Compare interpreters and compilers.

640


What are reserved words?

656


What is the heap in c?

646


Can you explain the four storage classes in C?

645






What is the difference between arrays and pointers?

637


Is that possible to add pointers to each other?

904


What does %d do in c?

547


What is the purpose of & in scanf?

598


What is break statement?

633


What is #define used for in c?

615


Is c weakly typed?

579


Function which gives a pointer to a binary trees const an integer value at each code, return function of all the nodes in binary tree.?

630


What is identifiers in c with examples?

678


What are Macros? What are its advantages and disadvantages?

649