Hehe, anyway, I just checked out my copy of C++ How to Program 3rd Edition, the book I'm planning to read first. Anyway, it says that the first 5 chapters are the "C" part of C++, datatypes arrays etc, and at the end of every chapter there's a Talking in OOP part, used to get the reader familiar with OOP concepts.
@Daved
The rest of the chapters are more C++ or oop chapters and as described before, the first 5 chapters are procedural programming. What do you think?
It's C-style C++. Not worthless, but not ideal. If you want to learn modern C++ you'll have to get another book. If getting another book will be difficult, then this one is fine. Just remember that you'll need to adjust your learning to account for the difference.
For example, if you stick with the 3rd edition then come on to the forum and ask a question about why this isn't working:you'll be told that you can't use == with C style strings and that you should be using C++ strings instead. I don't know if the third edition talks about C++ strings, but if it doesn't you'll have to go look them up outside of your book. The same thing will happen quite a few times. You'll still end up learning, just not quite as smoothly as you could.Code:char word[] = "hello"; char input[10]; cin >> input; if (input == word)
Is vector mentioned in the index at all? If not, then you'll be having to do a lot of research outside the book, and you'll probably end up buying a second book anyway.
Last edited by Daved; 11-04-2008 at 01:38 PM.
I'm not 100% sure, but I dont think vector is actually part of the C++ standard, its part of the STL.
It's part of the standard.
The STL is an informal name often used to refer to the containers and algorithms in the standard library. The name comes from the actual STL library from SGI (I think) that formed the basis for the completed standard library. However, when people refer to the STL now, they're almost always referring to the stuff inside the C++ standard.
Hmm, haven't seen vectors in my book, that's a negative.
Anyway, by pure chance I downloaded vector tutorials the day I learned basic C++.
I'm going to read the book, and after that I'll read some other books I can get my hands on, hopefully, I can get the C++ Primer,
although I'm having trouble finding Accelerated C++.
What do you think about this:
The C++ Standard Library: A Tutorial and Reference
That's more of a reference, or an intermediate tutorial (like someone transitioning). Meaning it assumes you are comfortable with C++ and just teaches you STL. It's not that hard finding e-books (wink wink - buy them if you like them). I really liked Accelerated C++, but I haven't looked into C++ How to Program (latest edition might be better, I don't know).
Warning: Have doubt in anything I post.
GCC 4.5, Boost 1.40, Code::Blocks 8.02, Ubuntu 9.10 010001000110000101100101
Still, I'll take the chance and read the third edition thoroughly and then read e-books, I can get a lot of e-books.
Maybe you're looking at too old a copy of the proposed standard.Originally Posted by abachler
Look up a C++ Reference and learn How To Ask Questions The Smart WayOriginally Posted by Bjarne Stroustrup (2000-10-14)
>> Nope, looking at a copy of the proposed standard (yeah im that old) now, vector isnt part of it.
Interesting. I'm looking at the actual standard, and vector is right there.
Originally Posted by ISO/IEC 14882
vector is in the actual standard, and also in the 1997 final public draft, which is available for free:
http://www.open-std.org/jtc1/sc22/open/n2356/
All the buzzt!
CornedBee
"There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
- Flon's Law
Hmmm, I'm planning on reading C++ Primer 4th after the book I mentioned.
ah, the 'new' c++98 standard, my copy is an older version published in 1994.