diff --git a/tests/factorial.ar b/tests/factorial.ar new file mode 100644 index 0000000..d98e99d --- /dev/null +++ b/tests/factorial.ar @@ -0,0 +1,10 @@ +let factorial(x) = do + let n = x-1 + if (n) return x*factorial(n) + return 1 + +let loop = 501 +let x = 500 +while (x) do + factorial(loop-x) + x=x-1 \ No newline at end of file diff --git a/tests/iteration-test.py b/tests/iteration-test.py deleted file mode 100644 index 5399247..0000000 --- a/tests/iteration-test.py +++ /dev/null @@ -1,3 +0,0 @@ -i = 1000000 -while i: - i=i-1 \ No newline at end of file diff --git a/tests/iteration.ar b/tests/iteration.ar new file mode 100644 index 0000000..2c929db --- /dev/null +++ b/tests/iteration.ar @@ -0,0 +1,3 @@ +let i = 1e7 +while (i) do + i=i-1 \ No newline at end of file