So, I have this question. Why does cout throws
error C2065: \'cout\' : undeclared identifier
I am using Visual Studio 2012 as an IDE and I
First of all:
#include
instead of #include "iostream"
#include "iostream"
Secondly, it is generally considered bad practice to write using namespace std;, even though most courses start with that. It is better to only use what you actually need, in your case:
using namespace std;
using std::cout;