When class Demo is used in Java Programs???
Answers
Answered by
2
Before you create objects in Java, you need to define a class.
A class is a blueprint for the object.
We can think of class as a sketch (prototype) of a house. It contains all the details about the floors, doors, windows etc. Based on these descriptions we build the house. House is the object.
Since, many houses can be made from the same description, we can create many objects from a class.
A class is a blueprint for the object.
We can think of class as a sketch (prototype) of a house. It contains all the details about the floors, doors, windows etc. Based on these descriptions we build the house. House is the object.
Since, many houses can be made from the same description, we can create many objects from a class.
Similar questions
India Languages,
6 months ago
Social Sciences,
6 months ago
Math,
1 year ago
Economy,
1 year ago
Math,
1 year ago