map function

Apply a function to each element of a vector or list