This question asks: "TRUE or FALSE: methods which are marked protected can be called on any subclass of the class in which the method is declared." The answer is given as TRUE. What does "called on any subclass" mean? That answer is certainly true if "on" means "in".
When I read "called on any subclass" I imagine we're talking about taking an instance of the subclass and using it to invoke the method, as in subclassInstance.protectedMethod(). This would make the statement FALSE since you can't do that from within an unrelated class. I think you're right that the question was meant to say "in" rather than "on".
I still think is it FALSE (so class A { protected void printName() { System.out.println("A"); } } class B extends A { protected void printName() { System.out.println("B"); } } class C extends B { protected void printName() { System.out.println("C"); }
static void main(String argc[]) { //HOW DO I CALL A's printName, I don't } }