Line 51 invokes member function earnings
on the object to which employeePtr
points. Recall that earnings
is declared virtual
in the base class, so the program invokes the derived-class object’s earnings
function—another example of dynamic binding.
18.218.91.239