🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

The great C++ myth

Started by
7 comments, last by Bully 24 years, 4 months ago
What I want to know is why do people, say that c++ is very hard. Maybe it is just MCP book publishers trying to get more sales. But alot of c++ books you pick up seem to day state that you should have previous experiance in another language as well. Which is certinly not the case. Why???? -David
" The fastest code is the code you don't call "
Advertisement
It is true that C++ is not really hard. However it is essential that you have some experience over another language.

By the mean of another language, i don''t speak for Basic or something. I''m speaking about ASM, or in the worst case Pascal.

Remember how things are when you start for the first time and you have noone to tell you some stuff... It seems hard to learn the meaning of pointers, memory chunks, etc...

PS: I don''t just recomend that people start with Pascal, but also that they should get into asm (at least with inline asm in Pascal). ASM is simple and essential if you want to understand how the CPU, etc. work.

PS: Remember how it is when you are just starting up, and you had noone to explain you all the ''weird'' things...

PS: Keep in mind that a few years ago, not everyone had internet...

I''m open to any discusion further.
c''ya
... LEMMINGS ... LEMMINGS ... LEMMINGS ... LEM..... SpLaSh!...Could this be what we stand like before the mighty One?Are we LeMmIngS or WhAt!? ;)
The best ground-up C++ tutorials I''ve seen are Who''s Afraid of C++ and Who''s Afraid of More C++. They don''t assume any language familiarity, which is a plus.

Many C++ tutorials assume that you already know C, which is a big time-saver if you do know C, but it''s certainly not always a good assumption.

(my byline from the Gamedev Collection series, which I co-edited) John Hattan has been working steadily in the casual game-space since the TRS-80 days and professionally since 1990. After seeing his small-format games turned down for what turned out to be Tandy's last PC release, he took them independent, eventually releasing them as several discount game-packs through a couple of publishers. The packs are actually still available on store-shelves, although you'll need a keen eye to find them nowadays. He continues to work in the casual game-space as an independent developer, largely working on games in Flash for his website, The Code Zone (www.thecodezone.com). His current scheme is to distribute his games virally on various web-portals and widget platforms. In addition, John writes weekly product reviews and blogs (over ten years old) for www.gamedev.net from his home office where he lives with his wife and daughter in their home in the woods near Lake Grapevine in Texas.

Admittedly, the basics of C++ aren''t very hard. However the nuances of C++ can be very hard to master. It''s difficult (not impossible) to explain how C++ is working internally without a good mastery of C. e.g. How virtual functions work, what RTTI is doing, etc. It''s only gotten worse as new functionality gets added to C++.
I agree... in one of the first books i read - C++ in 21 Days - The author kept going on about how hard pointers were, and then when he finally got around to explaining them they turned out to be not that hard. I much prefer an old C manual I have - it explains pointers on about the second page of their tutorial and it makes them seem simple!

Edited by - deakin on 2/8/00 3:17:56 AM
- DanielMy homepage
I''ve been telling people for a long time that they should start with C++. If it''s too hard, they can go back and learn something easier. Once they understand the basics of it, they can explore other areas as they move to mastery. It may not work for everyone, but it''s worked remarkably well for me. One thing that will help is to do what Chris Hargrove recommends: read everything you can get your hands on.
The ability to learn is about finding the right teacher for the right student, everyone finds different concepts hard and having some background programming knowledge is certainly a bonus when learning any language. Personally I don''t know any assembler (okay I want to but it''s on the backburner at the moment I''ve too much else to do) and I only vaguely understood Turbo Pascal before I was thrown into C++.
It actually took me 4 months to finally ''get'' the concept of linked lists (back when I was being badly taught Turbo Pascal), now the idea is easy and I figure I could explain it to any newbie in five minutes.

I''m probably wrong.

Because it''s all a question of previous experience and the way your mind works. I''ve found that, over the last six years, the more my mind focuses on the technical, mathematical world of computers the less ability I have for writing and other similar creativity. Everything becomes numbers.
If that''s how you mind works then the concept of using an array of pointers to pointers for controlling memory management may seem trivial. If your brain doesn''t work this way then you''re going to need the Dummies Guide to C++ not Stroustrup''s The C++ Programming Language (for those who don''t know, he invented the language). I''m currently reading the latter and some of technical jargon is obfuscating my understanding of subjects I already know well. This is no insult, he writes for people that think like he does and it''s an excellent reference manual. It contains more information than a handful of simpler texts but the information is not presented in a way that is clear to someone who doesn''t know a lot about computers already.
C++ should be learnable on it''s own, without any previous programming knowledge, it''s just a question of finding the right way to learn.

Mike
well actually you should tell people to start with pascal because that is why it was invented as a TEACHER language to learn the basic concepts and then you can go on and apply the syntax from other languages.
The question of which language to start with is more one of semantics than it is of syntax. The reason that most C++ books recommend a minimal background in programming is that they intend, while teaching you the syntax of C++, to also teach you the basics of the object-oriented paradigm. They do so in a subtle fashion...someone not familiar with programming in any language (in any form) might not notice. Someone used to writing iterative programs should notice, and hopefully realize and appreciate the differences. Thus more is gained by the reader if he/she already has some modest experience in programming.

It is the opinion of most people that object oriented programming is more difficult, conceptually, than iterative styled programming. Since very few C++ books teach the syntax of the language from a purely procedural standpoint, it is my assumption that they think a reader with some prior coding experience will be better poised to pick up the material. Perhaps.

The syntactic differences of languages are what most people refer to when they say one language is "harder" than another. C++ is not the hardest language out there, but someone with a good grounding in, say, C or Java should not have any problem with the syntax of C++ (familiarity with COBOL or Prolog might not help as much though... ).
------When thirsty for life, drink whisky. When thirsty for water, add ice.

This topic is closed to new replies.

Advertisement