localhostdotdev
searching Neon…
- 1.▲
- 2.▲
- 3.▲
- 4.▲
- 5.▲
- 6.▲
5 ms·
- 61.▲
- 62.▲
- 63.▲
- 64.▲
- 65.▲
- 66.▲
- 67.▲
- 68.▲
- 69.▲
- 70.▲
- 71.▲
- 72.▲
- 73.▲
- 74.▲
- 75.▲
- 76.▲
- 77.▲
- 78.▲
- 79.▲
- 80.▲
- 81.▲
blocks are the same as passing a function or a lambda in python: [1, 2, 3].map { |i| i + 1 }
[i + 1 for i in [1, 2, 3]]
def plus(i):
return i + 1
map(plus, [1, 2, 3])
map(lambda i: i + 1, [1, 2, 3]) - 82.▲
- 83.▲
- 84.▲