2 ms·
As an aside, the "power_it" function in Python can also be written as: map(lambda t: t ** 2, [1,2,3,4]) or even: [(lambda t: t**2)(x) for x in [1,2,3
by peripetylabs 14y ago
As an aside, the "power_it" function in Python can also be written as:
map(lambda t: t ** 2, [1,2,3,4])
or even:
[(lambda t: t**2)(x) for x in [1,2,3,4]]
- irahul 14y ago> [(lambda t: t2)(x) for x in [1,2,3,4]] Why would you have that lambda? [x**2 for x in range(1, 5)]