2009-06-27から1日間の記事一覧
http://projecteuler.net/index.php?section=problems&id=20 100!各桁の和 import Char main = print $ sumOfDigits $ product [1..100] --Problem16より sumOfDigits :: Integer -> Int sumOfDigits = sum . map digitToInt . show
http://projecteuler.net/index.php?section=problems&id=20 100!各桁の和 import Char main = print $ sumOfDigits $ product [1..100] --Problem16より sumOfDigits :: Integer -> Int sumOfDigits = sum . map digitToInt . show