a great C++ book?
hello again,
i ask this group because i trust in your intellect.
For a beginner to C++ what is your favorite book? A book that goes in depth of teaching the language. remeber i am a beginner, new to c++.
thank you
__________________________________________________
Do You Yahoo!?
Send your FREE holiday greetings online!
http://greetings.yahoo.com
Quoted 5 lines · samson swanson
For a beginner to C++ what is your favorite book? A book that goes in depth of teaching the language. remeber i am a beginner, new to c++.
Nicolai Josuttis, Object Oriented Programming in C++, Addison-Wesley 2001
This guy is on the C++ standartization comitee,the book is intended for complete beginners as for advanced programmers - it starts with the basic concepts and goes smootly into more advanced topics, it's fairly simple to understand and the examples are staright to the point and well explained. Besides this, it describes very good the concepts of OOP.
Greetings,
Todor
Quoted 3 lines · samson swanson
For a beginner to C++ what is your favorite book? A book that goes in depth of teaching the language. remeber i am a beginner, new to c++.
I really like the original book by Bjarne Stroustrop, he's the guy that designed the language and wrote what was supposed to be the C book for C++.
Signature · 2 lines
--- Larry McVoy lm at bitmover.com http://www.bitmover.com/lm
Hi Samson;
While the other books that have already been mentioned are very good, maybe even required, for the absolute beginner I reccomend Accellerated C++ by
Koenig and Moo. One book is not enough though, Accellerated C++ should be
supplemented with a good C++ reference.
Dave
Quoted 19 lines · samson swanson
hello again,
i ask this group because i trust in your intellect.
For a beginner to C++ what is your favorite book? A book that goes in depth of teaching the language. remeber i am a beginner, new to c++.
thank you
__________________________________________________
Do You Yahoo!?
Send your FREE holiday greetings online!
http://greetings.yahoo.com
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Quoted 7 lines · samson swanson
hello again,
i ask this group because i trust in your intellect.
For a beginner to C++ what is your favorite book? A book that goes in depth of teaching the language. remeber i am a beginner, new to c++.
If you already know C well, Bjarne Stroustrup's "The C++ Programming Language" is decent. If not, start with Kernighan and Ritchie's "The C Programming Language". Put the two next to each other and you might gain some insight into the creeping horror that modern C++ has become.
Signature · 1 line
"Love the dolphins," she advised him. "Write by W.A.S.T.E.."
Quoted 6 lines · Oliver Xymoron
Quoted 4 lines · samson swanson
hello again,
i ask this group because i trust in your intellect.
Quoted 8 lines
Quoted 3 lines
For a beginner to C++ what is your favorite book? A book that goes in depth of teaching the language. remeber i am a beginner, new to c++.
If you already know C well, Bjarne Stroustrup's "The C++ Programming Language" is decent. If not, start with Kernighan and Ritchie's "The C Programming Language". Put the two next to each other and you might gain some insight into the creeping horror that modern C++ has become.
It's hard to explain a love/hate relationship with C++. I think many systems programmers come to a point where they can "speak" C++ and do so in design conversations all the time, talking about the "objects" and the "methods", etc. But they program in C.
This sends a somewhat mixed message to the casual observer who might think that one language or the other is "better". The reality is that you want tp program in a fairly object oriented way but you also want to avoid "the creeping horror that modern C++ has become.".
Makes you wonder what would happen if someone tried to design a minimalistic C++, call it the "M programming language", have be close to C with the minimal useful parts of C++ included.
I've always said that if I get rich I'm going to fund some extensions to GCC to make associative arrays be a built in type, to make perl like regex's be a first class object, but maybe I was wrong, maybe I want to fund "M" :-) Sort of a moot point, I'm not rich.
Signature · 2 lines
--- Larry McVoy lm at bitmover.com http://www.bitmover.com/lm
Quoted 21 lines · Larry McVoy
Quoted 6 lines · Oliver Xymoron
Quoted 4 lines · samson swanson
hello again,
i ask this group because i trust in your intellect.
Quoted 8 lines
Quoted 3 lines
For a beginner to C++ what is your favorite book? A book that goes in depth of teaching the language. remeber i am a beginner, new to c++.
If you already know C well, Bjarne Stroustrup's "The C++ Programming Language" is decent. If not, start with Kernighan and Ritchie's "The C Programming Language". Put the two next to each other and you might gain some insight into the creeping horror that modern C++ has become.
It's hard to explain a love/hate relationship with C++. I think many systems programmers come to a point where they can "speak" C++ and do so in design conversations all the time, talking about the "objects" and the "methods", etc. But they program in C.
Quoted 5 lines
This sends a somewhat mixed message to the casual observer who might think that one language or the other is "better". The reality is that you want tp program in a fairly object oriented way but you also want to avoid "the creeping horror that modern C++ has become.".
An extract from the FAQ about C++: http://www.tux.org/lkml/#s1-4
"My personal view is that C++ has it's merits, and makes object-oriented programming easier. However, it is a more complex language and is less mature than C. The greatest danger with C++ is in fact it's power. It seduces the programmer, making it much easier to write bloatware. The kernel is a critical piece of code, and must be lean and fast. We cannot afford bloat. I think it is fair to say that it takes more skill to write efficient C++ code than C code. Not every contributer to the linux kernel is an uber-guru, and thus will not know the various tricks and traps for producing efficient C++ code."
Object-oriented programming is a good tool. One of many. But it shouldn't be a religion, nor do you need to write in C++ to make use of it. A good example of object-oriented programming done in C is the Xt toolkit.
Quoted 3 lines
Makes you wonder what would happen if someone tried to design a minimalistic C++, call it the "M programming language", have be close to C with the minimal useful parts of C++ included.
I'm sure lots of people have thought about this. A friend of mine and I sat down once and did a rough design for the "K" language, which was supposed to be "exactly like C, only better". Basically, we wanted to cherry-pick the good bits of C++, plus add some other things. As usual, lack of time is the enemy. Besides, what's point unless it gets widely used, and the chance of that is small.
Regards, Richard.... Permanent: [email protected] Current: [email protected]
Quoted 5 lines · On 20020101 Larry McVoy wrote:
Makes you wonder what would happen if someone tried to design a minimalistic C++, call it the "M programming language", have be close to C with the minimal useful parts of C++ included.
There are specs for something called 'Embedded C++'. You can run it on a cell phone, so it looks like little bloated...
Signature · 4 lines
J.A. Magallon # Let the source be with you... mailto:[email protected] Mandrake Linux release 8.2 (Cooker) for i586 Linux werewolf 2.4.18-pre1-beo #3 SMP Thu Dec 27 10:15:27 CET 2001 i686
[email protected] (J.A. Magallon) wrote on 02.01.02 in <[email protected]>:
Quoted 9 lines · On 20020101 Larry McVoy wrote:
Quoted 5 lines
Makes you wonder what would happen if someone tried to design a minimalistic C++, call it the "M programming language", have be close to C with the minimal useful parts of C++ included.
There are specs for something called 'Embedded C++'. You can run it on a cell phone, so it looks like little bloated...
Wrong metric, unless you mean you can run the *compiler* on the cell phone.
c99.pdf: 1412026 bytes
c++98.pdf: 2860601 bytes
And remember that interactions between features go up exponentially.
I think one of the worst design decisions for C++ (hindsight, of course) was to keep compatibility with C. The other bad one was to accept too many new features.
The Modula-3 standard (that's an OO variant of Modula-2) had as a language design goal that the language description should not take more than 50 pages. They overshot that, but it still was much less than 100 (somewhat less precise than C/C++, admittedly). As a result, that language (and consequently, programs in that language) is *much* easier to understand than C++.
That doesn't mean I'm in love with Modula-3. Actually, I don't even use it, and I do think (hindsight again) some of the design decisions were unfortunate. But I do think keeping an eye on the sheer mass of the spec is a good idea.
MfG Kai
Quoted 3 lines · On 20020101 Richard Gooch wrote:
Object-oriented programming is a good tool. One of many. But it shouldn't be a religion, nor do you need to write in C++ to make use
Use the right tool for the purpose. You bet for rewriting half the C++ runtime in C instead of not-using the bloated part of C++. Pretty. If you're going to program in a OO way, use an oo language. And I get tired of people saying C++ is bloat. My pupils at 5th course of Computer Science still think C++ is bloat. They have no idea on compilers. And they bless Ada.
A 5th level virtual function still has only a one-level indirection overhead when called. Low level code is just as efficient as C. If a C++ program is bloated it is the programmers matter, not the language.
Quoted 3 lines
of it. A good example of object-oriented programming done in C is the Xt toolkit.
kidding ????
Perhaps GTK+, but Xt...
By
Signature · 4 lines
J.A. Magallon # Let the source be with you... mailto:[email protected] Mandrake Linux release 8.2 (Cooker) for i586 Linux werewolf 2.4.18-pre1-beo #3 SMP Thu Dec 27 10:15:27 CET 2001 i686
Quoted 10 lines · J. A. Magallon
Quoted 3 lines · On 20020101 Richard Gooch wrote:
Object-oriented programming is a good tool. One of many. But it shouldn't be a religion, nor do you need to write in C++ to make use
Use the right tool for the purpose. You bet for rewriting half the C++ runtime in C instead of not-using the bloated part of C++. Pretty. If you're going to program in a OO way, use an oo language. And I get tired of people saying C++ is bloat.
Actually, I didn't say that C++ is bloat. I said C++ makes "it much easier to write bloatware". Big difference.
Quoted 2 lines
My pupils at 5th course of Computer Science still think C++ is bloat.
Good. That means they'll approach it with caution, rather than jumping on the bandwagon.
Quoted 4 lines
They have no idea on compilers. And they bless Ada. A 5th level virtual function still has only a one-level indirection overhead when called. Low level code is just as efficient as C. If a C++ program is bloated it is the programmers matter, not the language.
Not when the language seduces you into writing bloatware. The more powerful the language and the more abstract the concepts it supports, the further the programmer is taken away from understanding what's happening at the low level. That leads to bloatware.
If I had my way, no CS student would graduate unless they understood what's happening at the low level and had experience benchmarking and optimising code. A good start would be to have at least one assignment where they have to write a reasonably complex piece of code, in any language, and their marks are based on how fast the code runs. And the marks should be scaled down if everyone writes code which is much slower than the instructor's.
Regards, Richard.... Permanent: [email protected] Current: [email protected]
Followup to: <[email protected]> By author: Larry McVoy <[email protected]> In newsgroup: linux.dev.kernel
Quoted 5 lines
Makes you wonder what would happen if someone tried to design a minimalistic C++, call it the "M programming language", have be close to C with the minimal useful parts of C++ included.
Personally I have found that it's quite clean and easy to program in "C+" by simply using a C++ compiler and just not going wild with all the features that you *could* use. You don't *have* to use all of it, you know. In that way, your "M" language really becomes a particular *style* of C++ rather than a full-blown programming language in its own right. This is actually a Good Thing[TM], since it means you can leverage existing compilers and so forth.
Way back in the 0.99.x days we actually tried doing the Linux kernel using the g++ compiler, the main motivation for that was to get type-safe linkage. At that time, as everyone knows, g++ wasn't up to snuff; that has probably changed now. The LKML FAQ claims that "there would be no point" unless we started using C++ features left and right; personally I think type-safe linkage is plenty of reason enough.
I think it might be worth another attempt once gcc 3.x stabilizes enough that it's the accepted standard compiler. It will be more invasive this time around, because of the module system, but the benefit might be greater.
-hpa
Signature · 3 lines
<[email protected]> at work, <[email protected]> in private! "Unix gives you enough rope to shoot yourself in the foot." http://www.zytor.com/~hpa/puzzle.txt <[email protected]>
Quoted 7 lines · H. Peter Anvin
Personally I have found that it's quite clean and easy to program in "C+" by simply using a C++ compiler and just not going wild with all the features that you *could* use. You don't *have* to use all of it, you know. In that way, your "M" language really becomes a particular *style* of C++ rather than a full-blown programming language in its own right. This is actually a Good Thing[TM], since it means you can leverage existing compilers and so forth.
You've just described the reasons why Algol 68 is a Bad Thing(tm). Everyone has his own subset and almost nobody understands what exactly happens in others' code.
Quoted 7 lines
Way back in the 0.99.x days we actually tried doing the Linux kernel using the g++ compiler, the main motivation for that was to get type-safe linkage. At that time, as everyone knows, g++ wasn't up to snuff; that has probably changed now. The LKML FAQ claims that "there would be no point" unless we started using C++ features left and right; personally I think type-safe linkage is plenty of reason enough.
We can't get people to follow common style and you expect adherence to some subset of the language smaller than "compiler doesn't spit errors on that"? Dream on.
And then there is "six month ago I cud not spel injuneer and now I r won" crowd - and quite a few of them seem to be afraid of C. FWIC it is a damn good reason to stay with C...
On 01/01/02 Alexander Viro did speaketh:
Quoted 3 lines
And then there is "six month ago I cud not spel injuneer and now I r won" crowd - and quite a few of them seem to be afraid of C. FWIC it is a damn good reason to stay with C...
:) That's because they picked-up "Visual Basic for Dummies" and now they claim to be programmers. *sigh*
Mike
Signature · 3 lines
Michael P. Soulier <[email protected]>, GnuPG pub key: 5BC8BE08 "...the word HACK is used as a verb to indicate a massive amount of nerd-like effort." -Harley Hahn, A Student's Guide to Unix
Quoted 7 lines · H. Peter Anvin
Way back in the 0.99.x days we actually tried doing the Linux kernel using the g++ compiler, the main motivation for that was to get type-safe linkage. At that time, as everyone knows, g++ wasn't up to snuff; that has probably changed now. The LKML FAQ claims that "there would be no point" unless we started using C++ features left and right; personally I think type-safe linkage is plenty of reason enough.
Hardly - the problems it would solve are infrequent and the solution open numerous cans of worms.
Signature · 1 line
"Love the dolphins," she advised him. "Write by W.A.S.T.E.."
Quoted 10 lines · Michael P. Soulier
On 01/01/02 Alexander Viro did speaketh:
Quoted 4 lines
And then there is "six month ago I cud not spel injuneer and now I r won" crowd - and quite a few of them seem to be afraid of C. FWIC it is a damn good reason to stay with C...
:) That's because they picked-up "Visual Basic for Dummies" and now
they claim to be programmers. *sigh*
Mike
I got my degree in Physics, so I learned to program in Fortran. In
that day, however, there were folks who were clamoring for more C
programming in science. I took one look at it and gagged on the pointers
and mallocs. In my opinion, no scientist should trust C code for important numerical work unless he has too; that's why Fortran was created in the first place.
Anyhow, one of the local self-appointed Unix gurus was aghast at
my distaste for C's primitiveness. Alas, I feal justified today because
Perl, Java, C#, and Cyclone are proving that C is for systems programming and not for everyday use.
That much said, I still am only fluent in Fortran, shell, Perl (and a little
Tcl/TK), so I don't really consider myself a programmer, just a sysadmin with a clue.
Signature · 1 line
[email protected].