Bird
0
0

Which phase of the Node.js event loop executes setTimeout callbacks?

easy📝 Conceptual Q11 of 15
Node.js - Timers and Scheduling
Which phase of the Node.js event loop executes setTimeout callbacks?
ACheck phase
BTimers phase
CPoll phase
DClose callbacks phase
Step-by-Step Solution
Solution:
  1. Step 1: Understand event loop phases

    The Node.js event loop has multiple phases, each handling different types of callbacks.
  2. Step 2: Identify where timers run

    The timers phase is specifically designed to execute callbacks scheduled by setTimeout and setInterval.
  3. Final Answer:

    Timers phase -> Option B
  4. Quick Check:

    Timers phase = setTimeout callbacks [OK]
Quick Trick: Timers run in the timers phase, not immediately [OK]
Common Mistakes:
  • Confusing timers phase with poll phase
  • Thinking setTimeout runs immediately
  • Mixing check phase with timers phase

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Node.js Quizzes