repeat() js code example
Example 1: js string times
let string = 'Plumbus'
let count = 3
string.repeat(count); // -> 'PlumbusPlumbusPlumbus'
Example 2: repeat js
repeatStr = (n, s) => s.repeat(n);
Example 3: js repeat
function repeatStr (n, s) {
return s.repeat(n)
}
/////////////////////////////similar///////////////////////////////////////////
repeatStr = (n, s) => s.repeat(n);