Y
Hacker News
new
|
ask
|
show
|
jobs
by
undreren
1739 days ago
Haskell has “otherwise” as a built in constant that equals true. It reads better in some cases.
f n | odd n = 3 * n + 1 | otherwise = n \\ 2