The map works similarly to several of the other methods we've seen so far. It takes a function that receives an array element as a parameter and returns some value. Those values are collected into a new array, and that new array is returned by the map method.