Repeat a string: Difference between revisions

Forth
(Logo)
(Forth)
Line 44:
=={{header|E}}==
<lang e>"ha" * 5</lang>
 
=={{header|Forth}}==
<lang forth>
: place-n { src len dest n -- }
0 dest c!
n 0 ?do src len dest +place loop ;
 
create test 256 allot
s" ha" test 5 place-n
test count type \ hahahahaha
</lang>
 
=={{header|Fortran}}==
Anonymous user