+ 1
Why doesnt this code allow me to put an input?
#include <iostream> using namespace std; int main() { int a; cout << "Enter"; cin << a; cout << a; return 0; }
2 ответов
+ 5
cin has the << the wrong way around.
it should be
cin >> a;
+ 4
see here for more info: http://www.cplusplus.com/doc/tutorial/basic_io/