12345678910



Question 1: Point out the error, if any in the for loop.

#include<stdio.h>
int main()
{
int i=1;
for(;;)
{
printf("%d ", i++);
if(i>10)
break;
}
return 0;
}

1. There should be a condition in the for loop
2. The two semicolons should be dropped
3. The for loop should be replaced with while loop.
4. No error