diff options
author | David Robillard <d@drobilla.net> | 2009-03-30 18:47:32 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2009-03-30 18:47:32 +0000 |
commit | fdc794f5dc9de5b55fff71939ee4374ea38efa8f (patch) | |
tree | 3d09e93504ec9c11013a306fd6abb3949f01789f /test | |
parent | 454e8908d51d2bb8c83af69f69b2c72e9606967d (diff) | |
download | resp-fdc794f5dc9de5b55fff71939ee4374ea38efa8f.tar.gz resp-fdc794f5dc9de5b55fff71939ee4374ea38efa8f.tar.bz2 resp-fdc794f5dc9de5b55fff71939ee4374ea38efa8f.zip |
Compile things into separate build dir.
Move .tpr files to test dir.
git-svn-id: http://svn.drobilla.net/resp/tuplr@109 ad02d1e2-f140-0410-9f75-f8b11f17cedd
Diffstat (limited to 'test')
-rw-r--r-- | test/ack.tpr | 8 | ||||
-rw-r--r-- | test/fac.tpr | 7 | ||||
-rw-r--r-- | test/list.tpr | 3 |
3 files changed, 18 insertions, 0 deletions
diff --git a/test/ack.tpr b/test/ack.tpr new file mode 100644 index 0000000..1fe38d5 --- /dev/null +++ b/test/ack.tpr @@ -0,0 +1,8 @@ +(def ack + (fn (m n) + (if (= 0 m) (+ n 1) + (= 0 n) (ack (- m 1) 1) + (ack (- m 1) (ack m (- n 1)))))) + +(ack 3 10) + diff --git a/test/fac.tpr b/test/fac.tpr new file mode 100644 index 0000000..77e4776 --- /dev/null +++ b/test/fac.tpr @@ -0,0 +1,7 @@ +; Factorial +(def fac (fn (n) + (if (= 0 n) 1 + (* n (fac (- n 1)))))) + +(fac 5) + diff --git a/test/list.tpr b/test/list.tpr new file mode 100644 index 0000000..947fe97 --- /dev/null +++ b/test/list.tpr @@ -0,0 +1,3 @@ +(def l (cons 1 (cons 2 (cons 3 4)))) + +(car (cdr (cdr l))) |