C++ Primer compiler

Pages: 12
I am new to c++ and recently purchased the C++ Primer 5th Ed book. It advises they use the GNU Compiler 4.7.0. I have a computer with windows Vista on it. Would this be a good compiler to use or is there anything else that could be commended.
on a side note I do use Eclipse for Java programming and have seen there is a way to set Eclipse up for c++.

Thanks for your help
Personally I use the TDM compiler which is a windows port of GCC. Currently it is at version 4.8.1 (and finally supports threads!!!)
Really good compiler, when I run into bugs, I report them and the developers fix them ASAP :)
closed account (Dy7SLyTq)
there is also mingw, visual c++, clang (does that work on windows?), dev-bloodshed(which should NEVER EVER BE USED. EVER.) and i think thats it for the main ones.
I am looking to learn c++ on my own and purchshed the C++ primer book but
Looking through the forums i see all these different compliers, like TDM, mingw, GCC GNU.
What is the differnce between these? what is the differnce between a IDE and complier?

Any help would be greatly appreciated

closed account (Dy7SLyTq)
The compilers are different because they were written by different people. That means different error messages, different options, and different levels of support for features. Dont get too hung up with this because it doesnt matter too much when starting out, and if need be you can use multiple compilers. An ide is kind of an advanced text editor that has a bunch of tools in one. Code::blocks, geany, and visual studips are popular ones
"Code::blocks, geany, and visual studips are popular ones" popular ones of what?

Do you have any steps for installing a good compiler?
closed account (Dy7SLyTq)
sorry i meant visual studios. they are ides. what os are you using?
IDE stands for Integrated Developement Environment, btw. People got sick of useing plain-text editors and good ol' fashion cmd.exe and compiling manually, so somone wrote and IDE that did all of that and more. :)

Code::Blocks is the one I used when I first started. I installed it (comes with MinGW, which is a fine compiler) and was able to code immediately thereafter. I think you will find it good for beginners.

Once you understand everything, you can get NetBeans (which has boookmarks, more compiler options (C++ 11, strip symbols for releases, etc...)) without changing anything (but you can uninstall Code::Blocks if you want).

As a beginner, I found Microsoft Visual to be a pain in the arse. Not only that, but MSVC++ doesn't, by default, actually "support" C++, it like to push C++/CLI (you know, by making that the first thing you see in the projects list... horrible for beginners). If you want to write raw, inscrutable C++ in MSVC++, it takes experience that a beginner would find formidable to overcome.

After 2 years with C++ (writing nothing but console programs) I can shuffle C++ syntax like a pro poker player and his deck of cards (not implying I know it all), and I'm only now starting to write Graphical User Interfaces. I find it to be much MUCH easier to learn GUI with so much experience with C++ (not objects written in C++, just raw C++: ints, floats, vectors, strings, streams, .....). I highly recommend practicing C++ ritually, like I, until you can do the same.

OF COURSE: these are my opinions, and I took my time. If you want to challenge yourself (and it's an incredibly steep slope to climb) you can.
Last edited on
closed account (Dy7SLyTq)
People got sick of useing plain-text editors and good ol' fashion cmd.exe and compiling manually

the opposite actually with me. i got sick of ides wanting me to conform to a style (mine is pretty unique... sfml has the closest one) and realized i really like having my own collection of tools rather than what works with an ide.

when you said MSVC++ you mean visual studios. vc++ is the compiler
I am using Window Vista Home Premium SP2

I would like to say Thank you fo your hlep
closed account (Dy7SLyTq)
no problem. i would recommend code::blocks w/mingw. its a nice build for beginners. i dont have a problem with visual studios and vc++, except for the free version is very limited imo
IWishIKnew wrote:
Not only that, but MSVC++ doesn't, by default, actually "support" C++
That is not true.
well, not "support", per-say, but it doesn't "perfer". It takes some effort to get the infernal thing to let you create a terminal project in C++ (not C++/CLI). I can remember trying to get the darn thing to work for hours just to compile hello world. I eventually uninstalled it in favor of Code::Blocks.

Also, on another note, DTS makes a point: it is, however, your decision to use an IDE. You could just as well use notepad and the command prompt, but that would force you to learn how to run the compiler with the arguments necessary to compile your programs, before you've even made your first "hello world!". It's up to you.
Last edited on
closed account (Dy7SLyTq)
>but that would force you to learn how to run the compiler with the arguments necessary to >compile your programs
its a very worthy skill that you should have no matter your preference.
code::blocks w/mingw is this an ide or compiler?

I found this
is this a good steps to follow to install code blocks
closed account (Dy7SLyTq)
code::blocks is an ide. mingw is a compiler. i would download this: http://sourceforge.net/projects/codeblocks/files/Binaries/12.11/Windows/codeblocks-12.11mingw-setup_user.exe/download which will install it all for you
I started using code::blocks and mingw a couple weeks ago. I've made it about halfway through the tutorials on the website here and haven't had a problem with it so far.

I'm not really sure what all it's capable of but it seems kind of overkill. I was just looking for something to plug code into and have it debugged but code::blocks is what google recommended to me.
Garion - Where did you find the tutorials?
This is the link


I just started on the introduction part and have been slowly working through them. You won't find exercises or anything like that but I found it helpful to modify the examples then try to figure out how I broke them heh.

I just finished the classes part 1 section... i'm thinking it will be another couple weeks till i finish the rest. I need time to soak in the info after I read it. I wouldn't try to read it all at once. You'll overload your brain.
Last edited on
Thank You for your help, i finally have a compiler/IDE installed for C++

Now like my orignal thread post stated i am trying to work my way through the C++ Primer 5th edition. So how do i create a new program? I already created a project so do i just open the project and create a new file?
Pages: 12