February 2014
Beginner
1248 pages
62h 25m
English
• There are three ways to call a method—using a method name by itself to call another method of the same class; using a variable that contains a reference to an object, followed by a dot (.) and the method name to call a method of the referenced object; and using the class name and a dot (.) to call a static method of a class.
• There are three ways to return control to a statement that calls a method. If the method does not return a result, control returns when the program flow reaches the method-ending right brace or when the statement
return;
is executed. If the method returns a result, the statement
return expression;
evaluates the expression, then immediately returns the resulting value ...
Read now
Unlock full access