0
What is the difference between "endl" and "/n" ?
2 ответов
+ 14
"\n" is a scape sequence (a string of length 1) which inherited from C and cause a new line operation. "endl" is an object which does the same thing as "\n" and also flushes standard output buffer.
You probably ask what do you mean by flushing the standard output. The following link leads you through some examples.
[https://www.quora.com/What-does-it-mean-to-flush-the-output-stream-in-C++]