Hello guys, I guess I do not clearly get what is meant by " Object.keys(bob).length
should return 6" which is one of the points that I need to pass. In my code below I pass every single challenge but not the first one. What is meant by those keys? Are those keys meant like keys from an object or?
**My code so far**
var Person = function(firstAndLast) {
// Only change code below this line
this.details = {
"firstName": firstAndLast.split(" ")[0],
"lastName": firstAndLast.split(" ")[1],
}
this.getFirstName = function(){
return this.details["firstName"]
}
this.getLastName = function(){
return this.details["lastName"]
}
this.setFirstName = function(newFirstName){
this.details["firstName"] = newFirstName
}
this.setLastName = function(newLastName) {
this.details["lastName"] = newLastName
}
this.setFullName = function(newFullName) {
this.details["firstName"] = newFullName.split(" ")[0]
this.details["lastName"] = newFullName.split(" ")[1]
}
// Complete the method below and implement the others similarly
this.getFullName = function() {
return this.details["firstName"] + " " + this.details["lastName"];
};
};
var bob = new Person('Bob Ross');
bob.getFullName();
bob.setFirstName("Haskell");
bob.getFullName();
**Your browser information:**
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36
Challenge: Make a Person
Link to the challenge: