Scenario: a school students&staff database has to be developed with personal details of every people in the school.
Because students and teachers both have common properties, a master class is useful from which both groups will inherit some of their properties.
Object people: This object stores the general details of the people in the school, like gender, age, phone number and home address.
Object students: This objects inherits all the properties of the people class and adds some more properties specific to students, like grade, marks for subjects and days missed.
Object teachers: This object inherits all the properties of the people class and addso some more properties specific to teachers, like homeroom, days sick, salary and subjects teached.
In this scenario, only objects of teachers and students would be instantiated, but because they inherit from the people class, they will possess properties of this class. people is now a superclass while teachers and students are a subclass.