Declaring variables

JavaScript performance comparison

Test case created by Raymond

Test runner

Warning! For accurate results, please disable Firebug before running the tests. (Why?)

Java applet disabled.

Testing in CCBot 2.0.0 / Other 0.0.0
Test Ops/sec
"fast"
for(var i = 0; i < 1000; i++){
  var my_variable = 'This is my variable';
}
pending…
"slow"
var my_variable;
for(var i = 0; i < 1000; i++){
  my_variable = 'This is my variable';
}
pending…

Compare results of other browsers

Revisions

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

3 Comments

Ross Grady commented :

I think your "fast" and "slow" labels are inverted from what the .net magazine article suggested.

rndr commented :

Oh, i'm an idiot. Nevermind.