What is an Object in Java ?
We all know that Java is an Object Oriented Programming Language, which entirely rely on Objects and Classes. Any entity which has State and Behavior is known as Object, for example note, pen, bike, book etc. It can be either physical or logical. All the objects should have the below two characteristics
- State : State represents the bof the objects, Lets take car as example car has name, color, engine etc.
- Behavior : Behavior represents the functionality of that object. With car you can drive, apply breaking, change gear etc.