In Perl I can repeat a character multiple times using the syntax:
$a = \"a\" x 10; // results in \"aaaaaaaaaa\"
Is there a simple way to ac
For repeat a value in my projects i use repeat
For example:
var n = 6; for (i = 0; i < n; i++) { console.log("#".repeat(i+1)) }
but be careful because this method has been added to the ECMAScript 6 specification.