repeat
Returns a string that is a repeat of its argument.
Example
The expression
repeat('ha', 3)
will result in ‘hahaha’.
Syntax
repeat(string str, int rep)
- str :
string
to repeat - rep :
int
number of times to repeat str
Returns
string
Description
Function repeat
returns rep copies of the string specified by str.