Big O Notation

function addUpTo(n) {
    const start = performance.now();
    bigOVal = [];
    bigOCount = 0;
    let total = 0;
    for (let i = 1; i <= n; i++) {
      total += i;
      bigOCount += i;
    }
    const end = performance.now();
    elapsedTime = (end - start) / 1e3;
    console.log(`Elapsed time for addUpTo(${n}): ${elapsedTime.toFixed(4)} ms`);
    return total;
  }

Count: 0

Elapsed Time: 0.0000 ms