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 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 with the help
of method area (). In the main, define two instance variables a triangle and a rectangle and then call
the area() method in this two instance variables.
he user must have the option to delete a product that has been saved. The user must first enter the product code to be deleted. Next, the user must confirm whether they want to delete the product. Q.1.10 The user must also have the ability to update specific details of the product. For example, the user must first enter the product code and then confirm whether to update the following product details: • Update the product warranty. • Update the product price. • Update the product stock level
Create a program that takes in an even sized String and prints out the first half concatenated with
original string separated by a single space.
Sample run 1:
Enter a single string: HelloThere
Output: Hello Hello There