Y
Hacker News
new
|
ask
|
show
|
jobs
by
ludicast
3436 days ago
Agreed, plus obviously your "if" statement doesn't do the assignment to usefulMetric. One more way the ternary wins (along with functional languages that use "if"s as expressions).
2 comments
LgWoodenBadger
3436 days ago
a "final" declaration (in Java) would have pointed that out through a compilation error ;)
link
kbenson
3436 days ago
D'oh! Fixed. Thanks. :)
link