Vidyalelo
C# Programming · Q39

Control Flow Statements in C Sharp

Programming · C# Programming · question 39

Q39

What will be the output of the following C# code? static void Main(string[] args) int temp = 1; switch (temp << 2 + temp) default: Console.WriteLine("Example1"); break; case 4: Console.WriteLine("Example2"); break; case 5: Console.WriteLine("Example3"); break; case 8: Console.WriteLine("Example4"); break; Console.ReadLine();

A.
Example1
B.
Example3
C.
Example4
Answer
D.
Example2

Answer: Option C

Solution

Answer: Option C
No explanation is given for this question Let's Discuss on Board