Javascript dummies exersice 24


#1

here is my code but it does not work.

// Declare a variable on line 3 called
// myCountry and give it a string value.
var myCountry = “USA”;

// Use console.log to print out the length of the variable myCountry.
console.log(myCountry );

// Use console.log to print out the first three letters of myCountry.
console.log(myCountry.substring(0,3));


#2

You didn’t do that. Use .length to print out the length of the variable


#3

thanks anyway you are cool


#4

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.