15問目
http://projecteuler.net/index.php?section=problems&id=15
20×20の格子を通る経路の場合の数を求める。
40C20です。
main = print $ combination 40 20 combination :: Integer -> Integer -> Integer combination m n = div (fact m) (fact n * fact (m - n)) fact :: Integer -> Integer fact n = product [1..n]