Follow

@tindall@cybre.space back when i played with haskell i probably would have written that like

fizzbuzz :: Integer -> String
fizzbuzz x = case divisibleByMany x [3, 5] of
[ ... ]
where
divisibleByMany n = filter (\y -> n `mod` y == 0)

and if i were to be really obnoxious, i’m pretty sure that lambda would be correctly expressed by ((== 0) . (mod n))

Sign in to participate in the conversation
📟🐱 GlitchCat

A small, community‐oriented Mastodon‐compatible Fediverse (GlitchSoc) instance managed as a joint venture between the cat and KIBI families.