Baheeg Training and Test Exam

JavaScript Specialist (1D0-735)

Score: 0 / 0 answered

Progress: 0 of 1219 qs

time elap: 00:00

Question 1: What is the output of the following code snippet?

let x = 0;
for (let i = 0; i < 5; i++) {
  if (i === 3) break;
  x += i;
}
console.log(x);