using System;
public class A{
private int i = 7;
protected int F(int j){
return i + j;
}
}
public class B : A{
public void G(){
Console.WriteLine("i: {0}", i);
Console.WriteLine("F(5): {0}", F(5));
}
}
public class Client {
public static void Main(){
B b = new B();
b.G();
}
}
Answer the following questions before you run the program:
Does the instance of B, created in Main in Client, have an instance variable i?
Is the first call to Console.WriteLine in G legal?
Is the second call to Console.WriteLine in G legal?