Double Tilde vs. ParseInt (v15)

Revision 15 of this benchmark created on


Preparation HTML

<script>
  var i = '1.6',
      j;
</script>

Test runner

Ready to run.

Testing in
TestOps/sec
Double Tilde
j = ~~i;
ready
ParseInt
j = parseInt(i, 10);
ready
Math.floor
j = Math.floor(i)
ready

Revisions

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