MCQs > IT & Programming > JavaScript > What's the output? var printName = function() { console.log('Matt'); printName = function() { console.log('James'); }; }; var copy = printName; printName(); copy();

JavaScript MCQs

What will be printed to the console as a result of this code? var printName = function() { console.log('Matt'); printName = function() { console.log('James'); }; }; var copy = printName; printName(); copy();

Answer

Correct Answer: Matt Matt

Explanation:

Note: This Question is unanswered, help us to find answer for this one

JavaScript Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it

search

JavaScript Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it