Public Group

#### Archived

This topic is now archived and is closed to further replies.

# How did you guys learn C++ ?

This topic is 5459 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Hey, I am having trouble learning C++, I am not sure what I am doing wrong. I do not currently have a good C++ book, but will be getting one soon. I have Visual C++ 6, Sams teach your self C in 24hrs though. I am taking the ones online instead because I don't want to really learn C and the Visual C++ 6 book is geared more towards MS Visual C++, but I am using KDevelop. But, my question is, how did you guys learn it ? I sit and read the chapter over and over on variables and I can barely understand it.(all I can do is make, "My first C++ program" appear on the screen without any notes or books. And copy code from the book) I have tried taking them in the past. hen I tried again now for about a week. (but I have actually tried many more times than that, so in all, maybe a few months.) I want to learn how to program games in C++ so should I take game tutorials while I am learning C++ or after? Thanks in advance for replies. [edited by - HTML on October 12, 2003 4:26:47 PM]

##### Share on other sites
Are you in high school? If you are, you should consider checking to see if there are any programming classes at your school. If you''re not in high school, try a community college. Some people can''t learn from just looking at a book; you might need help that only a teacher can provide.

Just my two cents.

##### Share on other sites
If you can''t handle variables yet, forget about making games for a while.

Come up with some questions about the variables chapter, and ask them here. If you tell us exactly what you don''t understand, we can probably explain it for you.

As for how I learned C++, I read a book and made some programs. There wasn''t really much to it.

##### Share on other sites
Before I say anything else, dont even think about making games. Concentrate on learning the syntax and how to do things in a console.

That being said, go to www.cprogramming.com and go through their tutorials. Those tutorials helped me more than any others. If you have money for a book, I would suggest Sams Teach Yourself C++ in 21 Days, which is freely available on the internet (not illegally, either). I think there is another, "Thinking in C++", that comes recommended and is also freely available.

What exactly about variables is giving you trouble? Manipulating them? Using them? Testing them? Knowing which type holds what? We''re here to help.

##### Share on other sites
I don''t know if you''ve already taken algebra or not but I seriously recommend you learn a bit of algebra. I am almost positive that if you understand algebra, you will have no problems understanding the concepts of variables and how to use them.
As for how I learned C++, I wasn''t able to motivate myself to read a book I had bought and go through all the examples so I decided to enroll in a class in a community college (quite a few years ago ), and that helped me to jumpstart. I had no problems going beyond the lessons after that on my own with the help of books.

Good Luck.

##### Share on other sites
quote:
Original post by HTML
How did you guys learn C++ ?

Personally, I bought a book and started reading it, utterly confused. Then I copied code from the book without really understanding how it worked. Eventually, just for fun, I started changing the sample code into something completely different and suddenly realized: "Hey, I''m programming!". After that initial bump, everything got easy for a while. That is, until the next bump. And so on.
quote:

I want to learn how to program games in C++ so should I take game tutorials while I am learning C++

Might work, but it''s probably a good idea to learn the language basics first. Do the excercises in the book. Take your time, don''t rush.

##### Share on other sites
I picked up "C++ for Dummies" by Randy Davis. It was only $25, with CD, not$50, like most programming books. (Those prices are uncalled for).

Most "For Dummies" books kind of suck, but this one was surprisingly good. It covered almost all of the C++ topics you need to do any game programming, including complicated stuff like multiple inheritance, virtual functions, operator overloading, and so on. It was also very easy to understand.

The book came with the GNU compiler, but if you already have MSVC, it has instructions for that compileter as well.

It took me a while to go through it, as stuff like work came up, making me put the book down. But I rarely had problems understanding what was going on. If you do, put the book down for a few days, then come back to it.

Once I finished this book, it was easy to pick up a book focused on Game programming and understand everything it was talking about.

##### Share on other sites
Yeah, if you could put up some questions about what specifically you are having trouble with, most of us could be of greater help.

There are some general advices though: attend some programming class, learn how the computer works, try some easier language first [ever tried C? Basic? Any scripting language?], search the web. Keep it simple [meaning, forget games until you're done with C++]. And just don't give up because it is becoming hard and obscure. The rewards are worth all the sweat.

A somewhat useful online tutorial on C++:

A good book on basic computer architecture:
Structured Computer Organization - Andrew S. Tannembaum

--
Andre Fillipe
(bhzkun AT yahoo DOT co DOT jp)

[edited by - fillipe on October 12, 2003 5:29:03 PM]

##### Share on other sites
I would suggest the book "Learn to Program with C++" by John Smiley, absolutely wonderful book. It has a slight mix of fictional story in it, as its set in a classrmom setting, with ''students'' asking questions on the material. It''s a really effective book.

Or, if you got some scratch, you could go for the ''Intro to Game Programming'' course on GameInstitute. I''m enjoying it so far.

And, as some people said before, experimenting with code helps alot, too.

P.S. - If you are able to take a live class in C++ programming, do that instead.

1. 1
2. 2
3. 3
Rutin
18
4. 4
5. 5
JoeJ
12

• 14
• 22
• 9
• 31
• 18
• ### Forum Statistics

• Total Topics
632617
• Total Posts
3007475
• ### Who's Online (See full list)

There are no registered users currently online

×