ExamVeda
Login
Home
Classes and Objects in C Sharp
?

What will be the output of the following C# code?
 class abc
 {
     public static void a()
     {
         console.writeline("first method");
     }
     public void b()
     {
         a();
         console.writeline("second method");
     }
     public void b(int i)
     {
         console.writeline(i);
         b();
     }
 }
 class program
 {
     static void main()
     {
         abc k = new abc();
         abc.a();
         k.b(20);
     }
 }

Answer & Solution
Correct Answer: Option B
Let's discuss the solution. Join the discussion
Examveda
Question posted by Examveda
Community

Join the Discussion

No comments yet Be the first to discuss this question.