+ 1
What is the use of map function in python ?
syntax : map(a function ,a sequence )
1 Answer
+ 3
The best way to understand and learn is through trial and error.
map function takes any function and applies it to each element in the iterable you specified. For example, if I give you the sequence
a = [11, 13, 17, 19, 23, 29]
Try calculating cube of each item