Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
var-let-const4
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/127.0.0.0 Safari/537.36 OPR/113.0.0.0
Browser:
Opera 113
Operating system:
Windows
Device Platform:
Desktop
Date tested:
one year ago
Test name
Executions per second
const
3729430.0 Ops/sec
let
3374979.0 Ops/sec
var
2928615.0 Ops/sec
Script Preparation code:
function withConst(a,b) { const x = a + '10'; return x + b; } function withLet(a,b) { let x = a + '10'; return x + b; } function withVar(a,b) { var x = a + '10'; return x + b; }
Tests:
const
withConst(Math.random(), Math.random())
let
withLet(Math.random(), Math.random())
var
withVar(Math.random(), Math.random())