Join Slack
Powered by
<@U1KGMFWHY>: What is the advantage of `counts.put...
# announcements
r
Ruckus
06/28/2016, 9:19 PM
@christopher
: What is the advantage of
counts.put(it, 1 + counts.getOrElse(it, { 0 }))
over
counts[it] = 1 + (counts[it] ?: 0)
(other than
0
being calculated lazily)?
Open in Slack
Previous
Next