I was trying to see which methods of converting a string to a number in javascript are more performant, so I went to jsperf to see what might work best. However, I seem to be getting different results based on whether or not the initial variables are defined in the Benchmark.prototype.setup() function, or directly in the global scope.
Any ideas on why this might be happening?