Vidyalelo
C# Programming · Q89

Control Flow Statements in C Sharp

Programming · C# Programming · question 89

Q89

What will be the output of the following C# code? static void Main(string[] args) int a = -1; int b = -1; if (Convert.ToBoolean (++a = ++b)) Console.WriteLine("a"); else Console.WriteLine("b"); Console.ReadLine();

A.
a
B.
b
C.
Compile time error
Answer
D.
Code execute successfully with no output

Answer: Option C

Solution

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