Repeat a string: Difference between revisions
Content added Content deleted
PatGarrett (talk | contribs) (→{{header|360 Assembly}}: a correction) |
No edit summary |
||
Line 1,152: | Line 1,152: | ||
I don't know if there is a built-in function for this, but it is easily achieved with a For loop and Concatenate Strings.<br/> |
I don't know if there is a built-in function for this, but it is easily achieved with a For loop and Concatenate Strings.<br/> |
||
[[file:LabVIEW_Repeat_a_string.png]] |
[[file:LabVIEW_Repeat_a_string.png]] |
||
=={{header|Lambdatalk}}== |
|||
<lang scheme> |
|||
{S.map {lambda {_} ha} {S.serie 1 10}} |
|||
-> ha ha ha ha ha ha ha ha ha ha |
|||
or |
|||
{S.replace \s |
|||
by |
|||
in {S.map {lambda {_} ha} |
|||
{S.serie 1 10}}} |
|||
-> hahahahahahahahahaha |
|||
or |
|||
{def repeat |
|||
{lambda {:w :n} |
|||
{if {< :n 0} |
|||
then |
|||
else :w{repeat :w {- :n 1}}}}} |
|||
-> repeat |
|||
{repeat ha 10} |
|||
-> hahahahahahahahahahaha |
|||
</lang> |
|||
=={{header|langur}}== |
=={{header|langur}}== |