Home » C Programming » Loops » Question
  1. What will be the output of the following C code?
    #include <stdio.h>
    void main()
    {
    int k = 2;
    if (k == 2)
    {
    printf("Hello Interview Mania");
    continue;
    }
    }
    1. Hello Interview Mania
      Hello Interview Mania
    2. Hello Interview Mania
    3. Garbage value
    4. Compilation Error
    5. None of these
Correct Option: D

Compilation Error

main.c: In function ‘main’:
main.c:8:13: error: continue statement not within a loop
continue;



Your comments will be displayed only after manual approval.