Name

repeat — repeat a string

Synopsis

string repeat(str, count);
string str;
int count;

Description

Returns a string comprised of count repetitions of the string str. If count is negative then the result is undefined; if count is zero then the result is an empty string.

Example 45. repeat Example

print(repeat("-x-", 5"));   // prints -x--x--x--x--x-