another time the same FQ !!! C++ or C FIRST ??

This is a discussion on another time the same FQ !!! C++ or C FIRST ?? within the C++ Programming forums, part of the General Programming Boards category; im a beginner in programming .. but learning fast!
i am still wondering what would be the benefit to start ...

By that I mean use a C++ compiler but only learn the procedural side of the language. Use new and delete over malloc and use the C++ style of dealing with struct type declarations (IE without the need of the keyword struct every time).

C++ is a bit more typesafe than C and is therefore easier for someone to learn on. I don't recommend learning object-oriented programming until you understand the procedural programming extremely well, but do so in C++ not C.

>He wants to know if he should learn C and then C++ or just go right to C++.
That was my interpretation as well. The question is as irrelevant as asking whether to learn Ada before Pascal or just going right to Pascal, the decision is arbitrary. The relationship between C and C++ seems to confuse everyone into thinking that one should be learned first when it really doesn't matter.

C++ dynamic memory allocation is more typesafe and easier to learn with, etc. There are many reasons to "skip C" and go directly to C++. True, it doesn't make as much of a differenceas people think, but the difference is there none-the-less! Maybe he isn't aware of how C and C++ are related, you could have at least given a quick explanation rather than just saying "it's irrelevent."

>There are many reasons to "skip C" and go directly to C++.
I agree, my opinion is that C++ should be learned first, but it's just that, an opinion. I feel that C++ should be learned before Java too, but that seems kind of silly since C++ and Java are two different langauges (just like C and C++). When learning, it really doesn't matter what language you choose, they'll all teach you the basics of programming so that you can easily learn other languages. How quickly you learn or how well you learn is also insensitive to the language. I've known awful programmers who started with C++ and it didn't help, I've known superb programmers who started with BASIC and grew up with GOTO.

My advice when it comes to which language you should use to learn with is always the same: pick on that looks neat and go with it. Trying to compare and contrast languages is a waste of time unless you have very specific needs. If you have very specific needs then you're probably not just starting out, so such comparisons are irrelevant, which was my point initially.

THANKS

Thank you everybody so far!!!

Most of you are right, i guess, i should have asked first what the differences are of the Language C and C++ in order to find out whether it makes a difference to learn one before the other, or not!
From your reactions i have received a good impression with which to start. I started before with Basic ( Liberty Basic ) and went on to Visual Basic, but i wanted a more powerful language, that is not only windows based. And I think that C++ is just that !?
This is also why I asked about C or C++... I didnt know that those languages where not the same! What i had red befroe was that C++ was just an Update of C?!

I think it is important to know the differences between all the languages. For porogrammers who are doing this more then just a hobby, it is actually extemly important, because of all the major and minor advantages and disadvantages of all languages!

Go straight to C++

First I worked my way through "Teach Yourself C in 21 Days", then "Teach Yourself C++ in 21 Days".

It was complertely unnecessary to learn C first. The only advantage of going through both books was that there is material in the C book which is skipped-over in the C++ book (in order to make room for the C++ specific stuff). This also made it easier for me to go through the C++ book.

The main difference between C and C++ is that C++ allows classes and objects (i.e object oriented programming = OOP). An object is a particular instance of a class. The "21 Days" book uses an example where the class is Cat and the objects are Fluffy and Boots

C and C++ are so similar that I can write a C program and compile it with a C++ compiler!