Answer (Choose 1 answer)
class A{
public virtual void Print(){
Console.Write("Dot");
}
} class B: A{
public override void Print(){
Console.Write("NET"):
}
}
class Program{
static void Main(string[] args){
B obj = new B():
}
}
obj.Print():
A obj1 = new B():
obj1.Print():
Console.WriteLine():
The output will be:
A. An exception will be thrown
B. DotNET
C. NETDot
D. NETNET
R
38/50-CAP