Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- raindrops :: Int -> String
- raindrops n = tests id (show n)
- where
- tests = test 3 "Pling" . test 5 "Plang" . test 7 "Plong"
- test d s x | n `mod` d == 0 = const (s ++ x "")
- | otherwise = x
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement