aboutsummaryrefslogtreecommitdiff
path: root/examples/generated.csx
blob: 4d3d5fb3d5e1b56ad2d31d0a2f40c07110421aa9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
[set no [fn [x] [same x []]]]
[set outint [fn [n] [if [< n 0]
  [do [out 45] [outint [neg n]]]
  [if [< n 10]
    [out [+ 48 n]]
    [do
      [outint [div n 10]]
      [out [+ 48 [mod n 10]]]
    ]
  ]
]]]
[set map [fn [f l] [if [no l] []
  [pair [f [head l]] [map f [tail l]]]
]]]
[map [fn [n] [outint n] [out 10]]
  [quote [99 37 73 42]]
]
[set id [fn args args]]
[outint [[id 42 13 31] 2]]
[out 10]