Vidyalelo
C# Programming · Q82

Control Flow Statements in C Sharp

Programming · C# Programming · question 82

Q82

What will be the output of the following C# code? static void Main(string[] args) int a = 5; if (Convert.ToBoolean((.002f) -(0.1f))) Console.WriteLine("Sachin Tendulkar"); else if (a == 5) Console.WriteLine("Rahul Dravid"); else Console.WriteLine("Ms Dhoni"); Console.ReadLine();

A.
Rahul Dravid
B.
Sachin Tendulkar
Answer
C.
Ms Dhoni
D.
Warning : Unreachable Code

Answer: Option B

Solution

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