In today’s Programming Praxis challenge, our goal is to solve the second part of the billboard test, which is to find the fifth group of ten digits of e that sum up to 49. Reusing our definition of stream_e from the previous exercise, the solution becomes a simple one-liner:
main :: IO () main = print $ [x | x <- map (take 10) $ tails stream_e, sum x == 49] !! 4
Tags: billboard, bonsai, challenge, code, digits, e, Haskell, kata, praxis, programming
Leave a Reply