ExamVeda
Login
Home
This question belongs to C Program Control Structures
Control Structures
?

What will be the output of the following piece of code?
for(i = 0; i<10; i++);
printf("%d", i);

Answer & Solution
Correct Answer: Option A

Due to semicolon(;) at the end of the for loop, after 10 iterations for loop will be terminated and the result will be 10.

Examveda
Question posted by Examveda
Community

Join the Discussion

No comments yet Be the first to discuss this question.