RosettaCodeData/Task/Binary_strings/Forth/binary_strings-2.fth
Ingy döt Net 80737d5a6a new tasks
2013-04-09 00:46:50 -07:00

6 lines
163 B
Forth

: empty? ( str len -- ? ) nip 0= ;
: +c ( c str len -- ) + c! ;
: replace-bytes ( from to str len -- )
bounds do
over i c@ = if dup i c! then
loop 2drop ;