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

Learn Basic Algorithmic Thinking by Building a Number Sorter: Step 41 | freeCodeCamp.org
Any help would be appreciated. I guess their saying to change the variable to some thing else. Code.sort() assigned to variableupdate?

where is your code. you did not pasted it within your topic.

const sortedValues = insertionSort(inputValues);

updateUI(sortedValues);
Here it is, but I havent done anything yet. Am I simply to call/chain .sort()?
I usually relate the term call to a function.

you can update the sortedValues variable by assigning it the result of calling .sort() on the inputValues array.

yes, you simply chain sort as instructed

1 Like