16 lines
212 B
Text
16 lines
212 B
Text
|
# example|IterativeFibonacci
|
||
|
|
||
|
Declare module constant (prevents reloading when using `import`):
|
||
|
|
||
|
````
|
||
|
:example|IterativeFibonacci ;
|
||
|
````
|
||
|
|
||
|
----
|
||
|
|
||
|
````
|
||
|
:fib (n-m)
|
||
|
[ #0 #1 ] dip
|
||
|
[ over + swap ] times drop ;
|
||
|
````
|