#include <iostream>
using namespace std;
int main()
{
int a ;
while ( ( a = cin.get() ) != EOF )
{
cout << "hi" <<endl;
} // end while
}
I wonder why this outputs "hi" twice whenever I input once.
for example
input : 1 output : hi hi