I still don't know how this works with Visual Studio.
Supposedly it keeps my console open, but it doesn't. It still flashes and closes. Am I doing something wrong?
#include <iostream>
using namespace std;
int main()
{
int a;
cout << "Please enter an integer: ";
cin >> a;
if (a == 1)
{
cout << endl << "You typed 1.";
}
else
cout << "That's not 1.";
cin.get();
return 0;
}