C Sharp (C#) - Polymorphism and Abstract Classes
Which of the following is the correct syntax to declare a virtual method in a C# class?
virtual comes after the access modifier and before the return type and method name.public virtual void Display() { }. Options B and C have wrong order, D uses override which is for overriding, not declaring virtual.15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions