Node.js Output Prediction Medium +20 XP
Process Exit Code
What does process.exit(1) indicate?
Node.jsRead-only
if (error) process.exit(1);
What is the output?
Show answer and explanation
Answer: Abnormal exit / failure
process.exit(0) means success. process.exit(1) or any non-zero code indicates failure. CI/CD systems use this to detect errors.
Hint: 0 = success, non-zero = failure.
What this challenge tests
Output Prediction in Node.js: process, exit-codes.