Mercurial > repo
view Test.hs @ 4718:dd806b4cc1bf
<mroman> echo "echo \\`words --eng-1m 1\\` is to \\`words --eng-1m 1\\` as \\`words --eng-1m 1\\` is to \\`words --eng-1m 1\\`" >> bin/analogy
author | HackBot |
---|---|
date | Thu, 31 Jul 2014 11:27:26 +0000 |
parents | 7f957c1f4661 |
children |
line wrap: on
line source
import Data.List(inits);main = let p = 1 : zipWith (+) (map (*4) p) (map (sum . zipWith (*) p . reverse) (inits p)) in print $ p !! 1000