What is the function of \n? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 4

What is the function of \n?

what is the function of \n in This program 👉 https://code.sololearn.com/cLjIpcIbZ2W5/?ref=app

21st Feb 2018, 1:34 PM
Aditya Sahu
Aditya Sahu - avatar
3 Answers
+ 12
\n is used for new line, you can use println too
21st Feb 2018, 1:39 PM
Vukan
Vukan - avatar
+ 2
\ also let's u have things that u can't have normally in strings suppose to print Hi \ we ll need "Hi \\" "hi" we ll need. "\"hi\"" so it's also used to escape stuffs that we normally can't use inside string,
21st Feb 2018, 3:02 PM
Morpheus
Morpheus - avatar
0
new line
21st Feb 2018, 9:01 PM
Yonas
Yonas - avatar