diff options
Diffstat (limited to 'examples/strict.fusp')
-rw-r--r-- | examples/strict.fusp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/examples/strict.fusp b/examples/strict.fusp new file mode 100644 index 0000000..5795112 --- /dev/null +++ b/examples/strict.fusp @@ -0,0 +1,10 @@ +sub a b = code sub a b; + +take 0 _ = []; +take _ [] = []; +take n ![x:xs] = [x:take (sub 1 n) xs]; + +repeat 0 x = []; +repeat n x = [x:repeat (sub 1 n) x]; + +main = take 1 (repeat 200 5); |