Fix examples and contrib
parent
3839e481c5
commit
7542f5a026
|
|
@ -241,7 +241,7 @@ SYMBOL: first-arg
|
|||
dup .
|
||||
[ last-quot set ] keep
|
||||
[ call ] keep
|
||||
[ last car update-xt ] keep call
|
||||
[ peek update-xt ] keep call
|
||||
2dup swap unparse write " " write unparse print
|
||||
= [ "update-xt problem" throw ] unless ;
|
||||
|
||||
|
|
|
|||
|
|
@ -111,5 +111,5 @@ DEFER: (splay)
|
|||
USING: namespaces words ;
|
||||
|
||||
<splay-tree> "foo" set
|
||||
[ dup word-name "foo" get set-splay ] each-word
|
||||
[ dup word-name "foo" get get-splay drop ] each-word
|
||||
all-words [ dup word-name "foo" get set-splay ] each
|
||||
all-words [ dup word-name "foo" get get-splay drop ] each
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
IN: numbers-game
|
||||
USING: kernel math parser random io ;
|
||||
USING: kernel math parser io ;
|
||||
|
||||
: read-number ( -- n ) readln string>number ;
|
||||
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ SYMBOL: position
|
|||
SYMBOL: tape
|
||||
|
||||
! Initial tape
|
||||
20 zero-array >vector tape set
|
||||
20 0 <array> >vector tape set
|
||||
|
||||
: sym ( -- sym )
|
||||
#! Symbol at head position.
|
||||
|
|
|
|||
Loading…
Reference in New Issue