int main() { int temp; while (cin>>temp, !cin.eof()) { if (cin.bad()) { throw r
Because x is not an integer, the operator>> operator doesn't read anything, so when you clear the bit and try again, the same thing results.
x
operator>>