What is an object in Java?
Why Interviewers Ask This
This is a classic screening question for Java roles. Hiring managers ask it early in interviews to gauge your baseline understanding and determine if you can communicate technical concepts clearly.
Answer
An object is a runtime instance of a class. While a class is the blueprint, an object is the actual entity created from that blueprint — it occupies memory in the heap and has its own copy of the class's instance fields. You create an object with the new keyword: Car myCar = new Car();. Objects have three key characteristics: state (the current values of its fields), behavior (the methods it can execute), and identity (a unique reference/address in memory). In Java, objects are always accessed through references — you never manipulate the object directly.
Pro Tip
This topic has Java-specific nuances that differ from general programming. Highlighting those nuances in your answer shows expertise rather than generic knowledge.