unable to analyse a line of code in c++

what does this line of code mean and what is it's use?

cin.ignore(numeric_limits<streamsize>::max(), '\n');

Ignore everything until a newline
Last edited on
Obviously you've read the documentation (i.e., you're not an idiot).
http://www.cplusplus.com/reference/istream/istream/ignore/
So what part don't you understand?
Here is a topic I recently posted, it was about stream object and not cin. hopefully this can help you understand it better.

http://www.cplusplus.com/forum/beginner/238300/
Topic archived. No new replies allowed.