Repeating Character

Benchmark created by Soulcyon on


Preparation HTML

<script>
  var n = 10, c = "*";
</script>

Test runner

Ready to run.

Testing in
TestOps/sec
For Loop
for (var e = ''; e.length < n;)
e += c;
return e;
ready
Array Join
return Array(n).join(c);
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.