I think you're confusing an IDE with a compiler. The program most beginners use is called an IDE, for example, Code::Blocks, Visual C++, Bloodshed Dev-C++, etc. A compiler is what physically takes your code and turns it into an executable. The most common compilers are g++ and vc++. Visual C++ is
typically coupled with it's compiler and most freeware/opensource IDE's have an option that include a MingW version of g++ coupled with it. You need to either download a separate compiler, I suggest the MingW executable if you have no idea what you're doing, or you need to download a package that already includes a compiler.
The IDE itself doesn't affect what kind of program is generated. A lot of IDE's, however, will come with their own templates for what kind of programs it recognizes. You're also not required to use
just those templates either. Whatever tutorial you used can equally be applied to other IDE's. The only difference might be the buttons you click to compile, the amount of code completion the IDE offers in regards, and also the compiler the tutorial used might be out dated and the code in general may no longer be invalid.
If you downloaded Dev-C++ 5.0 beta 9.2 (4.9.9.2) (9.0 MB) with Mingw/GCC 3.4.2, then you should have had a compiler with it. However, if you downloaded the executable only, you are missing the compiler. I haven't used Dev-C++ in about 7 years since I stopped using it in high school.
If you are sure you have a compiler, try this code:
1 2 3 4 5 6 7 8
|
#include <iostream>
int main() {
std::cout << "Hello, World!";
std::cin.ignore();
return 0;
}
|
That should display "Hello, World!" on the console and wait for a button to be pressed.
1 2 3 4 5
|
int main() {
std::consoleout << 10; // Should cause an error
return 0;
}
|
If you try the above, it shouldn't compile and you should get an error. If neither of the above code snippets do anything for you, you're missing the compiler.