Below is the example of the string.repeat() Method.
- count: count is an integer value which shows the number of times to repeat the given string. The range of the integer “count” is from zero (0) to infinity.
Return values: It returns a new string that contains the specified number of copies of the string.
- Google Chrome 41 and above
- Edge 12 and above
- Firefox 24 and above
- Opera 28 and above
- Safari 9 and above