in which situation we would use endl; | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

in which situation we would use endl;

c++ endl

26th Dec 2016, 1:22 PM
Nitesh Ghimire
Nitesh Ghimire - avatar
2 Answers
+ 4
If you want to end the line, or in other words to put texts into different lines
26th Dec 2016, 4:17 PM
Filip
Filip - avatar
0
Use std::endl when you want also flush the stream.
26th Dec 2016, 1:57 PM
Ondřej Doněk
Ondřej Doněk - avatar