Junior — Senior
What text will appear in the console
livecode
Task condition
What will be the output of the program when creating an instance of ClassB?
public class ClassA
{
public ClassA()
{
Test();
}
public virtual void test()
{
Console.WriteLine("AAA");
}
}
public class ClassB : ClassA
{
public ClassB()
{
Test();
}
public override void Test()
{
Console.WriteLine("BBB");
}
}
public class Main()
{
Main()
{
ClassB obj = new();
}
}