![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Sep 2005
Posts: 11
Rep Power: 0
![]() |
Learning C before C++ - Important?
I want to start learning C++ and eventually Visual C++. However, I'm wondering how important it is to learn C before learning C++. Should I learn C first or can/should I just jump right into C++?
Also, what do people think of "C Primer Plus" and "C++ Primer Plus" for learning? Thanks for your opinions. |
|
|
|
|
|
#2 |
|
Hobbyist Programmer
|
Don't worry about C. C++ is a superset of C. There are no prerequisites for C++. I recommend to jump right to C++. I wish I did that.
|
|
|
|
|
|
#3 |
|
Newbie
Join Date: Sep 2005
Posts: 11
Rep Power: 0
![]() |
Thanks for the advice. I eventually want to get into game programming as a hobby and I've heard conflicting opinions from people about the importance of C for this .
|
|
|
|
|
|
#4 |
|
I eat cake for breakfast.
![]() ![]() ![]() ![]() Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9
![]() |
Well, game programming tends to utilise many C++ features such as classes and virtual functions, which aren't available in C. That said, learning C first will help you gain a deeper understanding of pointers, which are necessary for any large project. Hell, flip a coin or something. :p
|
|
|
|
|
|
#5 |
|
Expert Programmer
Join Date: Aug 2005
Location: Rotterdam, the Netherlands
Posts: 942
Rep Power: 4
![]() |
for 3d stuff, i don't think you need to know that much about pointers
![]() |
|
|
|
|
|
#6 |
|
I eat cake for breakfast.
![]() ![]() ![]() ![]() Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9
![]() |
Really? The whole of DirectX is based on pointers, or "LP"s as MS likes to call them.
|
|
|
|
|
|
#7 |
|
Resident Grouch
![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jun 2005
Posts: 6,453
Rep Power: 10
![]() |
You don't know C or C++ until you understand pointers. Visual C++ is not a language, it's a compiler brand. C++ very nearly is a superset of C (not precisely, but close). I'd personally recommend going with C++ right from the start -- the C is right there if you need it, a (near) subset.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code. Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers |
|
|
|
|
|
#8 |
|
The Oblivious One
Join Date: May 2005
Location: Ontario, Canada
Posts: 644
Rep Power: 4
![]() |
I own C++ Primer Plus and I think it is a fantastic book. Just make sure you know a little bit about basic programming concepts, and it will be a entirely worth it.
|
|
|
|
|
|
#9 |
|
Programming Guru
![]() Join Date: Oct 2004
Location: namespace std
Posts: 1,246
Rep Power: 5
![]() |
no, you don't have to learn c first, it can give you a better understanding of some basic concepts though...BUT you could also learn those in C++ depending on your learning resource. i always say learn c first, but you don't have to, i just think it's a little easier in helping you understand things better (mostly pointers and arrays...and hell, even the usage of primitive data types when forced to use "scanf/printf" instead of "cin/cout"). oh, and those books are pretty good. the SAMS books and the deitel and deitel books are all good (sams i think are cheaper though). go to amazon.com and search for the books USED...you can get very expensive books (albeit sometimes an older edition) for $2.00...literally...i've done it...many times. i really overuse the ellipsis don't i?
__________________
i put on my robe and wizard hat... Have you ever heard of Plato, Aristotle, Socrates?...Morons. |
|
|
|
|
|
#10 | |
|
Resident Grouch
![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jun 2005
Posts: 6,453
Rep Power: 10
![]() |
Quote:
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code. Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers |
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|