Declare String Variables confusion in accepted syntax

Declare String Variables confusion in accepted syntax
0.0 0

#1

Tell us what’s happening:

Your code so far

// Example
var firstName = "Alan";
var lastName = "Turing";

// Only change code below this line
#expected syntax as seen in the example:
var myFirstName="Willem"
var myLastName = "CR";
# this gives an error message

#accepted code:

var myFirstName = 'Willem';
var myLastName = 'CR';

I managed to pass the test by changing my input to only using a single apostrophe instead of a double apostrophe , however the syntax is a bit confusing, the example gives code with double " and so does the text leading up to the question, I think the leading text and example should be changed or the compiler should also accept double apostrophes,
Greetings Willem

Your browser information:

Your Browser User Agent is: Mozilla/5.0 (X11; Linux x86_64; rv:57.0) Gecko/20100101 Firefox/57.0.

Link to the challenge:


#2

Are you getting lint error ?


#3

I have just retryed the same code and now it works with " as well, perhaps the program ran the previously typed incorrect code and the problem couldv been remedied by refreshing, either way its working now :slight_smile:


#4

What are you talking about man.look i just tested and passed this test just by putting the exact strings you used :thinking: