What is Polymorphism

What is Polymorphism: What is Polymorphism: an overview, Changing Roles, Polymorphism with Interfaces.

Updated

  1. What is Polymorphism: an overview (Journeyman): Polymorphism means "many forms": one object can play many roles, like a teenager who is a student, a singer and an athlete.
  2. Changing Roles (Journeyman): Polymorphism means focusing on just the one role of an object that matters at the moment, as Chloe is a student, a musician and an athlete at different times of day.
  3. Polymorphism with Interfaces (Freelancer): Using an interface as a variable's type lets you treat an object as just one of its roles, such as treating a Teenager as a Student or a team as a list of Athletes.