0
What is better \n or endl?
3 Respostas
+ 2
https://www.sololearn.com/discuss/1956685/?ref=app
https://www.sololearn.com/discuss/265796/?ref=app
https://www.sololearn.com/discuss/78193/?ref=app
https://www.sololearn.com/discuss/1392532/?ref=app
https://www.sololearn.com/discuss/2410326/?ref=app
https://www.sololearn.com/discuss/650395/?ref=app
https://www.sololearn.com/discuss/127013/?ref=app
https://www.sololearn.com/discuss/2328711/?ref=app
https://www.sololearn.com/discuss/242949/?ref=app
https://www.sololearn.com/discuss/115622/?ref=app
https://www.sololearn.com/discuss/992807/?ref=app
https://www.sololearn.com/discuss/36076/?ref=app
0
Although both can be used. I believe \n is preferable as it's easier to use plus endl performs worse in comparison