+ 1

For getting a new line we have to put \n but it is not working in javascript of sololearn.Do you ever expirenced this here.

Please check it.

1st Aug 2017, 4:48 AM
romer
10 Answers
+ 1
@romer use <br> instead of \n
1st Aug 2017, 5:39 AM
Benneth Yankey
Benneth Yankey - avatar
+ 1
glad I could help. Happy coding!
1st Aug 2017, 5:48 AM
Benneth Yankey
Benneth Yankey - avatar
+ 1
this also in py unless you use the triple "
1st Aug 2017, 6:41 AM
Otumian Empire
Otumian Empire - avatar
+ 1
what is the salary of a software engineer??? plzz tell !!
1st Aug 2017, 3:36 PM
Subhash Sharma
Subhash Sharma - avatar
0
pls post the code to get help
1st Aug 2017, 5:22 AM
Benneth Yankey
Benneth Yankey - avatar
1st Aug 2017, 5:35 AM
romer
0
@benbright It's javascript not html.
1st Aug 2017, 5:41 AM
romer
0
the document.write writes into the DOM, and that's HTML. Use the <br> and see if it works as you want or not.
1st Aug 2017, 5:43 AM
Benneth Yankey
Benneth Yankey - avatar
0
@benbright I modified the code check it once more.
1st Aug 2017, 5:43 AM
romer
0
@benbright <br> works.
1st Aug 2017, 5:47 AM
romer