Bug Hunt Royale

Spot the bug, fix the code, and earn points.

3
60s
Current Score
0

Level 1

The Infinite Loop

This loop never ends! Fix the condition.

Type: Runtime Error

Hint

You need to increment `i` inside the loop.

buggy_code.js
function countToTen() {
  const i = 0;
  if (i < 10) {
    console.log(i);
    // Missing increment?
  }
}