Learn Basic Algorithmic Thinking by Building a Number Sorter - Step 12

Tell us what’s happening:

In my code to use forEach() on the declared empty array, I’ve used an empty callback (which basically just a declared function without any actions) using two parameters; num and i.

I’ve linked forEarch to the empty array and declared the empty callback as a parameter for the forEach. However, the checker is still not accepting my answer.

Your code so far

<!-- file: index.html -->

/* file: styles.css */

/* file: script.js */
// User Editable Region

const updateUI = (array = []) => {
  array.forEarch((num, i) => {});
}

// User Editable Region

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/136.0.0.0 Safari/537.36

Challenge Information:

Learn Basic Algorithmic Thinking by Building a Number Sorter - Step 12

Welcome to the forum @nguyenwintong

You have a typo.

Happy coding