Problem 16
The 16th problem of the project_euler site was fairly easy to solve. With a one-line function, I am able to calculate the sum of the digits of 2^x, for a given x as input:
Then, it was just a matter of calling the function with 1000 as input. The execution was really fast, so ghci presented (0.00 secs, 0 bytes).
blog comments powered by Disqus