I don’t understand how it differs from: “array of strings containing the HTML code to display the instrument cards, each string corresponding to an object in the instruments array. The strings should have this format <div class="card"><h2>[instrument]</h2><p>$[price]</p></div>”
Thank you, it worked, but I don’t understand the logic behind it: the function is now returning the exact same output as when I was using “instruments”, defined at the beginning of the function and whose elements were being replaced by the loop, as returning parameter, which was already giving the requested output.
Why was that method rejected, while a new array was accepted?
with the loop that replaces the elements inside the array, you were also changing instrumentsArr in some cases, do you think that is the expected behaviour?