What will be the output of the following C# code? [code] static void Main(string[] args) { try { Console.Write

Giao Linh

New member
What will be the output of the following C# code?
Code:
 static void Main(string[] args)
 {            
     try 
     {
         Console.WriteLine("csharp" + " " + 1/Convert.ToInt32(0));
     }
     catch(ArithmeticException e) 
     {
         Console.WriteLine("Java");        	
     }
     Console.ReadLine();
 }
A. csharp
B. java
C. run time error
D. csharp 0
 

Tìm kiếm

Back
Top