...

/

Solution Review: Instance of Array?

Solution Review: Instance of Array?

This lesson will explain the solution to the problem in the previous lesson.

We'll cover the following...

Solution #

Press + to interact
function check(){
var tempFunc = function () {}
tempFunc.prototype = Array.prototype
return new tempFunc instanceof Array;
}
console.log(check())

Explanation #

The exercise required you to write some code so that the line

return new tempFunc
...