added neg and bitnot to the stdlib and made a fib.sl example

This commit is contained in:
IgorCielniak
2025-12-25 12:20:11 +01:00
parent 2b8cd25499
commit e2b1368899
2 changed files with 32 additions and 0 deletions

16
fib.sl Normal file
View File

@@ -0,0 +1,16 @@
import stdlib/stdlib.sl
import stdlib/io.sl
: main
1 1 2dup 2dup puti cr puti cr
+
dup puti cr
rot
22 dup >r for
2dup + dup puti cr
rot
next
"-------" puts
r> 3 + puti
" numbers printed from the fibonaci sequence" puts
;