Anonymous user
Repeat a string: Difference between revisions
→{{header|ECL}}
(→{{header|Ruby}}: removed comment (not an operator but a method) and code demonstrating an error.) |
|||
Line 365:
=={{header|ECL}}==
After version 4.2.2
<lang>IMPORT STD; //Imports the Standard Library
STRING MyBaseString := 'abc';
RepeatedString := STD.Str.Repeat(MyBaseString,3);
RepeatedString; //returns 'abcabcabc'</lang>
Before version 4.2.2
<lang>RepeatString(STRING InStr, INTEGER Cnt) := FUNCTION
rec := {STRING Str};
|