Haskell
変更 階乗 - Wikipedia Haskell fact :: Int -> Int fact 0 = 1 fact n = n * fact (n - 1) main :: IO () main = do print (fact 10) -- > 3628800 Python def fact(n): if n == 0: return 1 return n * fact(n - 1) print(fact(10)) #-> 3628800 Ruby def …
(Emacs24.3, MacOSX10.8) install ghc The Glorious Glasgow Haskell Compilation System sudo port install ghc sudo port install hs-cabal-install zshrc or bashrc PATH=$HOME/.cabal/bin:$PATH Install package in Emacs M-x package-list-pakages イン…