Tell us what’s happening:
// running tests
myStr
should not contain any spaces
myStr
should contain the strings FirstLine
, SecondLine
and ThirdLine
(remember case sensitivity)
FirstLine
should be followed by the newline character \n
myStr
should contain a tab character \t
which follows a newline character
SecondLine
should be preceded by the backslash character \
There should be a newline character between SecondLine
and ThirdLine
myStr
should only contain characters shown in the instructions
Your code so far
var myStr; “FirstLine\n\t\SecondLine\nThirdLine”;
// Change this line
``
Your browser information:
User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.130 Safari/537.36
.
Challenge: Escape Sequences in Strings
Link to the challenge:
https://www.freecodecamp.org/learn/javascript-algorithms-and-data-structures/basic-javascript/escape-sequences-in-strings