30/30 Private Eye (Code is the same as other people in forum who got it to work)


#1


function StudentReport()
{
var grade1 = 4;
var grade2 = 2;
var grade3 = 1;

this.getGPA = function() 
{
    return (grade1 + grade2 + grade3) / 3;
};

}

var myStudentReport = new StudentReport();

for(var x in myStudentReport)
{
if(typeof myStudentReport[x] !== "function")
{
console.log("Muahaha! " + myStudentReport[x]);
}
}

console.log("Your overall GPA is " + myStudentReport.getGPA());

Oops, try again. Only a single thing should be logged to the console.

OUTPUT
Muahaha! undefined
Your overall GPA is 2.3333333333333335


#2

Well for now I just removed the console.log("Muahaha! " + myStudentReport[x]); not sure if that is the supost


#4

!==

Nonidentity operator.
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators


#5

I used the exact OP code and passed.