Error of undefined


I get the error: "TypeError: Cannot read property 'length' of undefined"


.length should be inside console.log(), just like you did with substring, you want to get length of string stored in myCountry variable, not myCountry string



also already covered next problem? You create a variable on line 3, which you want to use later, to get the length and substring of. Here:


myCountry is a string, it should be the variable


thanks a lot. You' re Deus ex machina.