Question from the Javascript test

Archived

Considering the following function:

function sum() {
    return arguments.reduce(function(total, nb) {
        return total + nb;
    }, '');
}

What will happen if we execute the following expression?

sum(1, 2, 3, 4);

Author: Jean-marie CléryStatus: Archived(New question!)Question passed 1401 times
1
Community EvaluationsNo one has reviewed this question yet, be the first!