Ticket #1136: mkj.hs

File mkj.hs, 446 bytes (added by igloo, 7 years ago)
Line 
1
2z = writeFile "/tmp/ian/J.hs" $ unlines j
3
4j = ["module J (a,b) where",
5     "(a,b) = let",
6     "    a0 = ()",
7     "    b0 = ()"]
8 ++ ["    a" ++ show i ++ " = a" ++ show (i-1) | i <- [1..numa]]
9 ++ ["    b" ++ show i ++ " = b" ++ show (i-1) | i <- [1..numb]]
10 ++ [" in ([a0" ++ concat [", a" ++ show i | i <- [1..numa]] ++ "],"
11       ++ "[b0" ++ concat [", b" ++ show i | i <- [1..numb]] ++ "])"]
12
13numa, numb :: Int
14numa = 300
15numb = 10000
16