Update repeatString.md

This commit is contained in:
David Wu
2017-12-23 16:02:20 +01:00
committed by GitHub
parent 401fd73dc6
commit 4281d0b8b5

View File

@ -9,6 +9,5 @@ const repeatString = (str="",num=2) => {
return num >= 0 ? str.repeat(num) : str;
}
// repeatString("abc",3) -> 'abcabcabc'
// repeatString("abc",0) -> ''
// repeatString("abc") -> 'abcabc'
```