Java class and object relationship

     In the real world, there are specific "entities", take the supermarket as an example: There are many customers in the supermarket, such as Zhang San, Li Si and so on. The customer is our abstract concept, and the abstract concept defined to the computer is our class, and the example created with the class is the "object", which corresponds to the entities in the real world one-to-one.




Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326413427&siteId=291194637