Tell us what’s happening:
Describe your issue in detail here.
Hi There,
Please help with solution of the following problem.
Problem - Use backslashes to assign a string to the myStr
variable so that if you were to print it to the console, you would see:
I am a "double quoted" string inside "double quotes".
My answer was - var myStr = “I am a “double quoted” string inside “double quotes”.”;
The out come - You should use two double quotes ( "
) and four escaped double quotes ( \"
).
Can you please help to locate my error?
Thank you
Your code so far
var myStr = ""; // Change this line
var myStr = "I am a \"double quoted\" string inside \"double quotes\".";
Your browser information:
User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.114 Safari/537.36
Challenge: Escaping Literal Quotes in Strings
Link to the challenge: