Y
Hacker News
new
|
ask
|
show
|
jobs
by
benhoyt
2266 days ago
This is actually a feature in Go, but you leave off the "true" condition entirely:
https://tour.golang.org/flowcontrol/11
I quite like it, as it cuts down on the amount of brace and if/else if noise.