posted 17 years ago
Hi all,
I am taking a practice exam and don't understand the answer to the following question:
Consider the following code:
What is the result?
A. Car
B. Vehicle
C. Compiler error at line 3
D. Compiler error at line 5
E. Exception thrown at runtime
I thought the answer was D, but apparently I'm wrong....it's A.
Why can class PE14 override the run() method if it is declared as private in class Vehicle?
Thanks.
-Jason