GkSeries.com

Q.

Study the following ā€˜Cā€™ program

#include <stdio.h>
void main ()
{ 
    int a = 7, b = 5;
    switch (a/a % b)
    { 
         case 1 : a = a-b;
         case 2 : a = a+b;
         case 3 : a = a*b;
         case 4 : a = a/b;
         default : a = a;
    } 
}

One the execution of above program, what will be the variable a?

[A] 2
[B] 5
[C] 7
[D] 12
Answer & Explanation
Option: [C]

DOWNLOAD CURRENT AFFAIRS PDF FROM APP

Please share this page

Click Here to Read more questions

Teacher Eligibility Test