cplusplus
.com
TUTORIALS
REFERENCE
ARTICLES
FORUM
C++
Tutorials
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs
Forum
General C++ Programming
C++ cin stream problem
C++ cin stream problem
Mar 30, 2013 at 4:56pm UTC
alantheweasel
(24)
Hi , i got a problem of cin concept :
i dont know what is the meaning of cin.clear() and cin.sync() ?
please help /_\ i have considered a long time
Mar 30, 2013 at 5:04pm UTC
cire
(8284)
cin.clear()
clears the error state of the stream.
cin.sync()
has no meaning, although in some compilers it will remove existing data from the buffer associated with
cin
.
ignore
would be a better choice than
sync
Mar 30, 2013 at 8:32pm UTC
Stewbond
(2827)
http://cplusplus.com/reference/ios/ios/clear/
http://cplusplus.com/reference/istream/istream/sync/
Topic archived. No new replies allowed.