Yashfunctions

Benchmark created by Yash on


Test runner

Ready to run.

Testing in
TestOps/sec
declaration
function fun_declaration(){
    console.log('Hoisted to Top');
}

fun_declaration();
ready
expression
var myVar; // undefined

myVar = function () {
    console.log('Annoymous Function assigned to Var');
};

myVar();
ready
declaration_parameters
function fun_declaration(a, b){
    console.log('Hoisted to Top', a+b);
}

fun_declaration(10, 20);
ready
expression_parameters
var myVar; // undefined

myVar = function (c, d) {
    console.log('Annoymous Function assigned to Var', c+d);
};

myVar(5, 7);
ready

Revisions

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