2

I cannot distinguish the two terms. How about you?

3 Answers 3

2

Every object is an instance of a type. The word instance is used instead of object when describing member scope (i.e., static vs. instance). The word object is usually used instead of instance when referring to the target of a reference (e.g., a variable or field).

1

For many (probably most) purposes, there's no real difference. You can get into some fringe areas, such as C, which defines essentially anything (but a function) that has an address as being an "object" -- but of course, nothing in C is an "instance" the way that term is typically used (i.e., an instance of a class). Then again, it's all a matter of definitions -- as long as you and whomever you're talking with agree on what the words mean, it doesn't matter a whole lot whether you call something an "instance" or an "object" or a "blarfle".

0

Object is a more general term. Anything is an object, it may not an instance of particular type. For most common purposes, those terms can be interchanged especially in the context of a program.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.