What will be the output of the following C# code?

public static void Main(string[] args)
 {
     double ZERO = 0;
     Console.WriteLine("RESULT OF DIVISION BY ZERO IS :{0}",  (0 / ZERO));
     Console.ReadLine();
 }

a) 1
b) exception argument is thrown
c) NaN
d) 0

1 thought on “What will be the output of the following C# code?”

Leave a Comment