aboutsummaryrefslogtreecommitdiff
path: root/examples/stdlib.stem
diff options
context:
space:
mode:
authorPreston Pan <preston@nullring.xyz>2024-01-20 02:38:26 -0800
committerPreston Pan <preston@nullring.xyz>2024-01-20 02:38:26 -0800
commita9d6c221d7686e3055593359b02125a3f20ab3e5 (patch)
treeea9037ae83c28910f5fddf4844ffbb9563dbf94e /examples/stdlib.stem
parent640f9a3f5be5528dd4f8ed658cfe4d06d833e4c9 (diff)
add map, filter might work?
Diffstat (limited to 'examples/stdlib.stem')
-rw-r--r--examples/stdlib.stem29
1 files changed, 0 insertions, 29 deletions
diff --git a/examples/stdlib.stem b/examples/stdlib.stem
deleted file mode 100644
index df81cd8..0000000
--- a/examples/stdlib.stem
+++ /dev/null
@@ -1,29 +0,0 @@
-evalstr [ strquote eval ] func
-include [ fread evalstr ] func
-
-# Author: Preston Pan
-neg [ 0 swap - ] func
-
-# Author of loop function: Andrei S
-loop [
- swap dup 0 > [
- swap
- dup eval
- swap 1 - swap loop
- ] [ dsc dsc ] if
-] func
-
-# Author: Matthew H
-dupd [ [ dup ] keep ] func
-over [ dupd swap ] func
-dup2 [ over over ] func
-dip2 [ swap [ dip ] dip ] func
-while [ dup2 [ [ ] if ] dip2 over [ while ] [ dsc dsc ] if ] func
-
-loop-times [ dup2 [ swap [ ] if ] dip2
-dup [ 1 - loop-times ] [ dsc dsc ] if ] func
-
-d>base [ [ pow * "" swap ] keep2
-
-[ [ over ] [ [ dup2 / floor * swap over - ] keep [ [ "0" "1" "2" "3" "4" "5" "6" "7" "8" "9" "↊" "↋" ] vat swap + ] with dip2 ] while dsc2 dup len(str-len) ] dip
-- dup2 tail [ head "." ] dip + + ] func