1. What is a function parameter?
A function parameter is a variable used in a function. Function parameters work almost identically to variables defined inside the function, but with one difference: they are always initialized with a value provided by the caller of the function.
Function parameters are defined in the function declaration by placing them in between the parenthesis after the function identifier, with multiple parameters being separated by commas.
2. Why do functions need parameters?
Functions need parameters so they know how to work. Parameters are like directions or boundaries in terms of what you want the function to do and so it knows what to do.