because a extends b, b is the superclass
You cannot access the methods in c if b overrides them.
Steven please can you explain your statement in reference to the following code below,
In the code above, engine() is a method present in LuxaryCar, Buick and BuickLeSabre but I am still accessing method engine() of LuxaryCar. I think that was the question that Alec had.
suppose we have a class a which extends b and b in turn extends c
all three classes have a method tell();
now how do i call the method tell of c from a
Also Steven please can you explain this particular statement with reference to what doubt Alec had,
You cannot access the methods in c if b overrides them.
I think you forgot to mention
Where you cannot access the methods and Why ?, I think after that explaination your answer would be complete.