2 ms·
Good points, I tend to mix it up, rarely going parens-free style, but also not parens by default either. If you wanted to be really explicit you could do:
by virtualwhys 13y ago
Good points, I tend to mix it up, rarely going parens-free style, but also not parens by default either.
If you wanted to be really explicit you could do:
list.filter(x=> isEven(x)).foreach(x=> println(x))
yuck ;-)
- ponzao 13y agoThat example is not quite equivalent, because now you are not passing `isEven` or `println` as arguments, you are passing anonymous functions that call `isEven` and `println`.