Write a program that defines a shape class with a constructor that gives value to width and height.
The define two sub-classes triangle and rectangle, that calculate the area of the shape
In the main, define two variables a triangle and a rectangle and then call the area() function in this two varibles.
Write a program with a mother class and an inherited daugther class.Both of them should have a method
void display ()that prints a message (different for mother and daugther).In the main define a daughter and call the display() method on it.
Write a probram with a mother class animal. Inside it define a name and an age variables, and set_value() function.Then create two bases variables Zebra and Dolphin which write a message telling the age, the name and giving some extra information (e.g. place of origin).