Explain the difference between class and object

What will be an ideal response?


Class and object are often used interchangeably. And often, no harm results: class is an abstraction of similar objects and an object is a concrete manifestation of a class. (Sentences would become very awkward if everywhere we repeat "class and/or objects" or "class and its instances.") In majority of cases, what we say about classes also applies to objects, and vice versa. It is in those minority of cases that the distinction is crucial: class is the concept, object is the realization of the concept. Class is the cookie cutter, object is the cookie. If we declare that the cookie cutter is round, we imply that the cookie would be round, too. But if we say that we want to eat a cookie, it is unlikely that we mean to eat the cookie cutter as well.

Business

You might also like to view...

Which of the following is not a practice used to create a flexible workplace?   

A. Job sharing B. Telecommuting C. Gainsharing D. Part-time work E. Compressed workweeks

Business

Contrast the responsibilities of operations management, middle management, and top management. Explain the different information needs for each level of management

Business

Among the generational groups in U.S population, the ________ are still the wealthiest generation in U.S. history

A) baby boomers B) Generation Xers C) Millennials D) echo boomers E) Silent Generation

Business

The decision to use overbooking will

A) lead to upset customers and a high cost of providing them space. B) lead to unutilized assets and lost revenue. C) lead to reduced profits. D) depend upon optimization to be successful.

Business