Basic help - CPP

icor1031

[H]ard|Gawd
Joined
May 29, 2010
Messages
1,295
Free compiler, and starter's tutorial?

I know HTML, so I have some experience with programming - if that's relevant.

Thanks.
 
Ahhh .. I just downloaded this last night and am now playing around with it:
Code:
http://www.microsoft.com/express/Downloads/
Microsoft VS 2010 Express and it is free! I don't have a tut for it yet so hope someone else will recommend one! :)
 
HTML is not programming.

Visual C++ Express is a good, free compiler. As for learning C++, I have never found any online tutorials to be particularly good. You should really get a book like Accelerated C++.
 
As an Amazon Associate, HardForum may earn from qualifying purchases.
If you happen to have a linux machine at hand (e.g. at university, or for whatever other reason), you can also use gcc. It's just a compiler, though - not an IDE.
 
I agree a book is a good place to start if your only experience is html. The first couple of chapters of a decent c++ book are usually designed to hold your hand through the language.
 
That's the book I am about halfway through right now.
I really like it, as I am still fairly new to C++. It's not hard to follow, the examples are clear and I had heard that everyone gets tripped up on pointers in C++ when they learn, but the book does a good job of explaining them.
I have seen that book recommended more than once.
 
That book follows a very different teaching style from Accelerated C++. In C++, the age of the book is certainly not correlated with its 'good-ness' and usefulness, unlike books for languages like Java or Python which go through major language changes more frequently. The last ratified C++ standard was C++03 (which was errata changes and minor additions to C++98), and don't forget that C++ had existed for far longer before that. Prata's 5th edition book is markedly similar to his 4th edition, which was published in 2001 or so, and the 5th edition is from 2004.

Prata's book teaches C++ in a very C-centric way (focusing on raw pointers and arrays, C-style strings first, waiting until much later to discuss C++ constructs), whereas Accelerated C++ teaches C++ constructs and styles from the start (using the standard library more like <vector> and <string>, and not even mentioning raw pointers until the tail end of the book). If you wanted to start off with C instead, I would instead recommend The C Programming Language

Not to mention that Prata's book is about 1200 pages long (I completed his book front to back way back in the day), which is about twice the length of Accelerated C++ and CPL combined. I used to recommend Prata's work more, but after reading some of the other introductory books in C++, I have shifted to recommending ones that teach with an upfront C++ focus more.

If you want a book that exists in digital form, then I don't think anything I'd recommend exists in that form (and CPL is 20 years old!)
 
Last edited:
As an Amazon Associate, HardForum may earn from qualifying purchases.
Is there any reason I should start with C first?

cpp is 'the' language, right?
 
It's A language, but what are you learning it for? Many languages exist because they have different strengths. C++ is general purpose, multi-paradigm, and while it's one of my languages of choice, it's not the language I use for everything (it has to compete with Python, Java, Scala, and even normal C).

If you want to learn C++, then learn C++. Certainly there will be cross-pollination as C++ is a superset of C and inherits much from C, but you can write a lot of C++ without having to use C-style constructs.
 
And, indeed, the idiomatically correct ways to do things in C and C++ are often different. C code can be (and very often is) legal C++, but that doesn't mean it's how you'd do it if you set out to write C++.

(I sort of like straight C, it's a fairly small and simple language.)
 
learn the concepts of programming... any language syntax will then come naturally.

I don't program for a living, but I find that the most programming I do anymore is with scripting languages like php, bash, and perl. I still want to learn python, but haven't had a need yet.

It's all in what you want to get out of it.
 
Back
Top