Examveda

What will be the output of the following C# code snippet?
class Program
{
    static void Main(string[] args)
    {
        double x = 2.0;  
        double y = 3.0;
        double z = Math.Pow( x, y );
        Console.WriteLine(z);
        Console.ReadLine();
    }
}

A. 2.0

B. 4.0

C. 8

D. 8.0

Answer: Option C


This Question Belongs to C Sharp Programming >> Miscellaneous In C Sharp

Join The Discussion

Related Questions on Miscellaneous in C Sharp