Multiple choice general knowledge science & technology

void main() { int i=0; int j = ++i; if(j>i) main(); } the program compiles. }

  1. True

  2. False

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

The program compiles. i=0, j=++i makes j=1 and i=1, so j>i is false. The recursive call never executes, but compilation succeeds regardless. Runtime behavior doesn't affect compilation.