When do uncaught exceptions generate events?
A. When handlers are registered
B. When handlers are deregistered
C. When handler functions are called
D. When handlers do not have a matching catch clause
Answer: Option A
Solution(By Examveda Team)
Uncaught exceptions generate events, if any handlers are registered. Otherwise, the exception just makes Node print an error and exit.process.on("uncaughtException", function(e) { console.log(Exception, e); });
Join The Discussion