Java - Polymorphism
Consider these classes:
class Employee { void work() { System.out.println("Employee working"); } } class Manager extends Employee { void work() { System.out.println("Manager managing"); } } class Developer extends Employee { void work() { System.out.println("Developer coding"); } }How can runtime polymorphism be used to execute the work() method for different employee types?