7. 物件宣告與建立
Type of value to be returned,
which can be of any type or
class. If void, the method
does not return a value.
Type of value to be returned,
which can be of any type or
class. If void, the method
does not return a value.
Name of the
method.
return type methodName( arg1, arg2, … argn) {
This is the
body of the
method
// Executable code goes here
}