Multiple Choice
Consider the following code snippet: Employee anEmployee = new Programmer() ;
AnEmployee.increaseSalary(2500) ;
Assume that the Programmer class inherits from the Employee class, and both classes have an implementation of the increaseSalary method with the same set of parameters and the same return type. Which class's increaseSalary method is to be executed is determined by ____.
A) the hierarchy of the classes.
B) the variable's type.
C) the actual object type.
D) it is not possible to determine which method is executed.
Correct Answer:

Verified
Correct Answer:
Verified
Q51: Consider the classes shown below: public class
Q52: Insert the missing code in the following
Q53: Consider the Counter class below. public class
Q54: Consider the following code snippet: Vehicle aVehicle
Q55: Consider the classes shown below: public class
Q57: A class from which you cannot create
Q58: Consider the following code snippet: public class
Q59: Consider the Counter class below. public class
Q60: A class that represents the most general
Q61: A class that cannot be instantiated is