Y
Hacker News
new
|
ask
|
show
|
jobs
by
breuleux
4064 days ago
Yes. The compiler detects whether the return value is used or not to determine whether to accumulate the results in an array or not. Also, unlike forEach and map you can use continue or break.