Im attempting the Hello World program, but it always gets the build errors menu, even when i copy a correct version from the internet. Here is the one i am currently trying:
// Hello World, by Omegas Squared
// Include the iostream library
#include <iostream>
// Use the standard namespace
using namespace std;
void main ( )
{
// Print text to the screen
cout << "Hello world!" <<endl;
}
If someone could please help me out that would be great
I just made this one in visual, and it worked. What file are you writing? A .cpp file?
@Zhuge: return 0 is only needed when not using void.
@Wmheric: You can compile a single .cpp file in VC++. Also, you have to use return 0. That makes it return nothing. and thus has the same effect as void.