22.
What is the purpose of the "return" keyword in JavaScript?
To exit a loop or conditional statement.
To mark the end of a function.
To return a value from a function.
To assign a value to a variable.
Correct: B, C
The "return" keyword is used to mark the end of a function and specify the value to be returned from that function. It allows a function to provide a single value as output, which can then be used in the rest of the program. Using "return" outside of a function, such as in a loop or conditional statement, will cause an error.