Tell us what’s happening:
Describe your issue in detail here.
Your code so far
const myStr = "FirstLine
\t\\SecondLine\
\rThirdLine";
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.45 Safari/537.36
Challenge: Escape Sequences in Strings
Link to the challenge:
Hello there.
Do you have a question?
If so, please edit your post to include it in the Tell us what’s happening section.
Learning to describe problems is an important part of learning how to code.
Also, the more information you give us, the more likely we are to be able to help.
You can’t write a string across multiple lines like that in Javascript. You need to use tme newline escape character.
I wrote it as const myStr = “FirstLine\n\t\SecondLine\n\r\ThirdLine”;
You might want to looks up what \r which is carriage return is doing.
Tell us what’s happening:
Describe your issue in detail here.
Your code so far
const myStr = "FirstLine\t\\\SecondLine\n\r\ThirdLine".;
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.45 Safari/537.36
Challenge: Escape Sequences in Strings
Link to the challenge:
You are Not almost there sadly!
Immediately after your FirstLine
you should have a newline represented by \n
that should be followed by a tab \t
then an escaped backslash \\
then SecondLine
and so on.
Build it up bit by bit until what see on screen matches.
1 Like
this may seem really silly but I cant get back into it to make the changes,I tried every tab tab in history
Why not just click the link you supplied above?
1 Like
Thanks,Ill know for the future,Ill let you know when I get it right,thanks again for your input
system
Closed
May 24, 2022, 10:18pm
10
This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.