27/30 Question about another solution


#1

What about that solution?

for(lang in languages){
    if(!Number(languages[lang])){
        console.log(languages[lang]);
    }
}

27/30 It works but there must be a better way
#2

The difficulty here is that there are more types than just string and number. Rather than test all the types we don't want, how about test for the type we do want, 'string'.

for (var lang in languages) {
    if (typeof languages[lang] === 'string') {
        console.log( ... );
    }
}