Computer Science, asked by 28ranjita, 10 months ago


Predict the output of the following C programs
void main()
int i=3;
while(i<10)
printf("%d\n", i);
i++;
getch();

Answers

Answered by rani49035
1

Answer:

3 \\ 4 \\ 5 \\ 6 \\ 7 \\ 8 \\ 9

Explanation:

hope this will help you

Answered by AskewTronics
0

Compile Time error :

Explanation:

  • The above program holds the two type of syntax error which are as follows:
  1. There is no header file, which holds the code of predefined function which is used in the program.
  2. There is no curly braced to define the scope of the main function. it is necessary because every function needs to define his scope so that the compiler can understand the execution start and endpoint.
  • If the user fixes the above-defined error then the above code will execute an infinite loop because it also needs curly braces so that the increment operation comes in the scope of the for-loop.

Learn More:

  • C program : https://brainly.in/question/3999878

Similar questions