1.

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 clauseThis question was addressed to me in an international level competition.This interesting question is from Server-Side JavaScript in portion Server-Side and Client-Side Scripting of JavaScript

Answer»

Correct OPTION is (a) When HANDLERS are registered

For explanation I would SAY: The on() method and addListener() method PERFORM the same task of acting as an event emitter. The on() and addListener() method is used for registering handlers.



Discussion

No Comment Found

Related InterviewSolutions