object you reference your cell phone number variable piece of paper with your cell phone number written on it method call someone calls you and asks you to do something return value you finish the work you were asked to do and hand over what you did
The various things an object contains—its variables and its methods—are called the members of that object. The members of an object are accessed using dot notation, which looks like this:
Usually the objectReference is contained in a variable,
but not always.
If you want to run a method of the object, use the method name.
If it needs parameters (values supplied to the method),
they go inside
) like this:
objectReference.methodName( parameter )
) with a method name,
even if it needs no parameters.
length() method need