can it possible to acees the virthual method using the
override method object?
plz give me the example
Answer Posted / javed khan
public class zzz
{
public static void Main()
{
yyy x = new xxx();
x.test();
}
}
class yyy
{
public virtual void test()
{
System.Console.WriteLine("base calss.");
}
}
class xxx : yyy
{
public override void test()
{
System.Console.WriteLine("derived calss.");
base.test();
}
}
Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
Can you inherit multiple abstract classes in c#?
What is difference between ilist and list in c#?
What are concrete classes?
What is argument in c#?
Is linkedhashset synchronized?
Is there throws keyword in c#?
Is void a class?
Which .gang of four. Design pattern is shown below?
What are the uses of namespaces?
Is c# good for games?
Which function is the entry point for a DLL in MS Windows 3.1?
Explain the difference between private and shared assembly?
What is throw in c#?
What is the value which is accepted by all data types ?
What is parseexact c#?