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
cin.get(ch)
cin.get(ch)
Sep 9, 2012 at 2:53am UTC
vw4x4
(21)
1)why do we write cin.get(ch) and not cin>>get(ch)?
2)is cin.get(ch) a single function or a combination of cin and get()?
Sep 9, 2012 at 2:56am UTC
chrisname
(7395)
1. Because the second one makes literally no sense at all.
2. get() is a method of std::istream, which is a class. std::cin is an instance of the std::istream class. I don't know what you mean by "combination of cin and get()".
Topic archived. No new replies allowed.