7.1-1_Designing Methods Flashcards
1
Q
What are the (9) components of a method definition?
A
access modifier optional specifier return type method name parentheses parameter-list exception-list curly braces method body
2
Q
What is called the method signature?
A
Method name + Parameter List
3
Q
How to call a method?
A
To invoke a mehod, Just type its method-signature -> Its name, followed by the parameter list within parentheses.
4
Q
What are two important method definition rules?
A
📝️⚠️ Java allows the Optional Specifiers to appear before the Access Modifier.
📝️⚠️ The return type goes to the left of the method’s name