Home » C# Programming » Polymorphism

Which of the following statement is correct about the C#.NET code snippet given below? public class Sample { public int x; public virtual void fun() { } } public class DerivedSample : Sample { new public void fun() { } }

Correct Answer: DerivedSample class hides the fun() method of base class.

← Previous Question Next Question→

Discussion & Comments

No comments yet. Be the first to comment!
Join Discussion