MCQ PracticeSingle Best AnswerTopic: Javascript loops MCQ
Q
When an exception is thrown, what step will the interpreter take?
Question ID
#5069
Subchapter
Javascript loops MCQ
Action
Choose one option below
Choose Your Answer
Click an option to check whether your answer is correct.
A
The interpreter stops its work ✔✖
B
The interpreter throws another exception ✔✖
C
The interpreter jumps to the nearest enclosing exception handler ✔✖
D
The interpreter throws an error ✔✖
C
Correct Answer: C
Explanation
When an exception is raised in a jump statement, the interpreter will navigate to the closest exception handler, this handler could be located either in the same function or in an outer function that invoked it.