mirror of
https://github.com/bobbimanners/EightBall.git
synced 2025-02-19 16:31:31 +00:00
Updated Example: Factorial (markdown)
parent
d2286cdd0b
commit
8d16f78b35
@ -11,3 +11,5 @@ This example shows how EightBall can support recursion. I should point out that
|
|||||||
return val * fact(val-1)
|
return val * fact(val-1)
|
||||||
endif
|
endif
|
||||||
return -1 ; ' Never get here
|
return -1 ; ' Never get here
|
||||||
|
|
||||||
|
`fact(3)` calls `fact(2)`, which calls `fact(1)`, then finally `fact(0)`.
|
Loading…
x
Reference in New Issue
Block a user