30.
What happens when the return keyword is used inside a JavaScript function?
It continues the function execution and ignores the return statement.
It throws an error and stops the script execution.
It pauses the function execution until a value is provided.
It immediately ends the function execution and returns a value back to the caller.
Correct: D
When the return keyword is used inside a JavaScript function, it immediately ends the function execution and returns a value back to the caller. Any code written after the return statement will not be executed.