In this lesson, you’ll see that map()
is a built-in function that is one of the functional programming primitives (or building blocks) available in Python. It’s useful in a number of contexts.
map()
takes two arguments: an iterable (like a list) and a function. It then applies that function to all of the elements in the iterable. It outputs an iterator of items that are the result of the function called on the items in the first iterator.
Arif Zuhairi on Sept. 25, 2020
What does it means with it stops when the shortest iterable is exhausted?