Method Parameter
noun
say it: “METH-ud puh-RAM-uh-ter” /ˈmɛθəd pəˈræmətər/
A named input listed in a method's parentheses that receives a value each time the method is called.
What is Method Parameter in Java?
Method Parameter — A named input declared by a method.
class OrderCalculator {
int total(int price, int quantity) {
return price * quantity;
}
}
In a sentence
- “The parameter price in calculateTax(double price) holds whatever amount the caller passes in.”
Level: Apprentice · More Java terms at this level
Updated