-
-
Notifications
You must be signed in to change notification settings - Fork 10
/
lib_tests.txt
155 lines (149 loc) · 3.07 KB
/
lib_tests.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
__ num
3 4 max
3 4 min
3 odd
2 odd
3 even
2 even
__ list
[1 2] head
[1 2] top
[1 2 3] length
[1 2 3] 0 [+] foldr
[1 2 3] 0 [+] foldl
[1 2 3] 2 dropl
[1 2 3] 1 split_at
[4 5 6] 1@
[4 5 6] [3-] map
[7 8 9] [quote] map
[1 2] [3+] map [4 5 6] [7+] map .
[1 2 3] 0 [+ dup ->str] map_with
[4 5 6] [odd] filter
3 4 listdup
[1 2 3] reverse
[4 2] [3 1] merge
[5 3 4 1 2] sort
[[2 "a"] [3 "b"]] "a" assoc
[[2 "a"] [3 "b"]] "b" assoc
[1 2 3] [30 20 10] [+] zip
[1 2 3 4] [5 6 7 8] 0 [[*] dip21 + dup 10* swap] zip_with
[[1, 2+, 4, *]] concat
[5, [ 2*, 3+ ]] scatter
[[ 2 dup, 3* dup]] gather
0 [1+] iteratel
[[1 2, 3 4, 5 6]] unzip
__ stack
[1] pull
[1 2] pull2
[1 2 3] pull3
[1 2 3 4] pull4
[1 2 3 4 5] pull5
[1 2 3 4 5 6] pull6
[1 2 3 4 5 6 7] pull7
[1 2] tail
[1 2 3] tail2
1 2 3 rev3
1 2 nip
1 2 tuck
1 2 over
1 2 3 over2
1 2 3 4 over3
1 2 3 4 5 over4
1 2 dup2
1 2 3 4 5 6 7 8 swap2
1 2 3 4 5 6 7 8 swap3
1 2 3 4 5 6 7 8 swap4
1 2 3 4 5 6 7 8 swap5
1 2 3 4 5 6 7 8 swap6
1 2 3 4 5 6 7 8 swap7
__ control
True A B ifte
False A B ifte
1 A [1+] dip11
1 A [1+ dup] dip12
1 A [1+ dup dup] dip13
1 A [1+ dup dup dup] dip14
1 A [1+ dup dup dup dup] dip15
1 A [1+ dup dup dup dup dup] dip16
1 2 A [+] dip21
1 2 A [+ dup] dip22
1 2 A [+ dup dup] dip23
1 2 A [+ dup dup dup] dip24
1 2 A [+ dup dup dup dup] dip25
1 2 A [+ dup dup dup dup dup] dip26
1 2 3 A [+ +] dip31
1 2 3 A [+ + dup] dip32
1 2 3 A [+ + dup dup] dip33
1 2 3 A [+ + dup dup dup] dip34
1 2 3 A [+ + dup dup dup dup] dip35
1 2 3 A [+ + dup dup dup dup dup] dip36
1 2 3 4 A [+ + +] dip41
1 2 3 4 A [+ + + dup] dip42
1 2 3 4 A [+ + + dup dup] dip43
1 2 3 4 A [+ + + dup dup dup] dip44
1 2 3 4 A [+ + + dup dup dup dup] dip45
1 2 3 4 A [+ + + dup dup dup dup dup] dip46
1 2 3 4 5 A [+ + + +] dip51
1 2 3 4 5 A [+ + + + dup] dip52
1 2 3 4 5 A [+ + + + dup dup] dip53
1 2 3 4 5 A [+ + + + dup dup dup] dip54
1 2 3 4 5 A [+ + + + dup dup dup dup] dip55
1 2 3 4 5 A [+ + + + dup dup dup dup dup] dip56
1 2 3 4 5 6 A [+ + + + +] dip61
1 2 3 4 5 6 A [+ + + + + dup] dip62
1 2 3 4 5 6 A [+ + + + + dup dup] dip63
1 2 3 4 5 6 A [+ + + + + dup dup dup] dip64
1 2 3 4 5 6 A [+ + + + + dup dup dup dup] dip65
1 2 3 4 5 6 A [+ + + + + dup dup dup dup dup] dip66
1 [2+] $
1 2 [+] $$
1 [2+] $keep
1 2 [+] $$keep
1 [2+] peek
[1] [2+] peek_cmp
1 [2+] ->
[1] [2+] ->cmp
1 [2+] [10*] fork
[1] [2+] [10*] fork_cmp
10 [1+] [2+] [3+] fork3
[10] [1+] [2+] [3+] fork_cmp3
1 2 [2+] [10*] para
1 2 [10*] both
1 [odd] [2+] if
1 [even] [2+] if
1 [dup 2+ swap odd] ifdo
1 [dup 2+ swap even] ifdo
1 2 in2
0 [3+] [10<] iterate
0 [3+ dup 10< !] while
0 [3+] 4 times
[Nothing] [3+] 0 maybe
[2 Just] [3+] 0 maybe
[1 Left] [10*] [2+] either
[1 Right] [10*] [2+] either
5 [dup dup 2/ dup [-] dip21 swap2 1 > !!] [->str] [["+" ++] dip11 ++] bitree
__ logic
False False or
False True or
True False or
True True or
False False and
False True and
True False and
True True and
False False implies
False True implies
True False implies
True True implies
1 2 default
1 0/ 2 default
1 2 3 vifte
1 0/ 2 3 vifte
1 valid
1 0/ valid
__ algorithm
49 21 gcd
2 5^
[1 2 3] sum
__ io
Array 3 42 write_array 3 [7/] update_array 3 read_array