adplus-dvertising
frame-decoration

Question

What will be the output of the given set of code?
static void Main(string[] args)
 {
     int[] x = { 80, 82, 65, 72, 83, 67 };
     fun(x);
     Console.ReadLine();
 }
 static void fun(params int [] b )
 {
     int i;
     for (i = 5; i >=0 ; i--)
     {
         Console.WriteLine(Convert.ToChar(b[i]));
     }
 }

a.

67 83 72 65 82 80

b.

P R A H S C

c.

C S H A R P

d.

80 82 65 72 83 67

Posted under C# programming

Answer: (c).C S H A R P

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. What will be the output of the given set of code?