Java Object Concept
Object
Object is representative of the class and is responsible for memory allocation of its data members and member functions.An object is a real world entity having attributes (State / data type) and behaviors (functions). An object can be considered a "thing" that can perform a set of related activities. The set of activities that the object performs defines the object behavior.
Example:
In our class room, All students are an individual Object. They have different
name and color.
Programming Language Example: All are the Different different object
int a=10;
float b1=20.10f;
String s1="Name";
MyClass x;
Object is representative of the class and is responsible for memory allocation of its data members and member functions.An object is a real world entity having attributes (State / data type) and behaviors (functions). An object can be considered a "thing" that can perform a set of related activities. The set of activities that the object performs defines the object behavior.
Example:
In our class room, All students are an individual Object. They have different
name and color.
Programming Language Example: All are the Different different object
int a=10;
float b1=20.10f;
String s1="Name";
MyClass x;
Comments
Post a Comment