diff options
Diffstat (limited to 'benchmark/other-lang/fact.rb')
-rw-r--r-- | benchmark/other-lang/fact.rb | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/benchmark/other-lang/fact.rb b/benchmark/other-lang/fact.rb index c75320824..7e97b22b3 100644 --- a/benchmark/other-lang/fact.rb +++ b/benchmark/other-lang/fact.rb @@ -1,13 +1,13 @@ -def fact(n)
- if n < 2
- 1
- else
- n * fact(n-1)
- end
-end
-
-i=0
-while i<10000
- i+=1
- fact(100)
-end
+def fact(n) + if n < 2 + 1 + else + n * fact(n-1) + end +end + +i=0 +while i<10000 + i+=1 + fact(100) +end |