27.
What are parameters in JavaScript functions?
They are used to define the data type of a function.
They are used to store the global scope of a function.
They are predefined values that a function returns.
They are named variables passed into a function.
Correct: D
Parameters in JavaScript functions are named variables passed into a function. Parameter variables are used to import arguments into functions. They help make functions more flexible and reusable as different values can be passed in each time the function is called.
function myFunction(parameter) {
console.log(parameter);
}
const argument = "Hello!";
myFunction(argument);