Jump to content

Is all lost?

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
2 replies to this topic

#1
TechieJeff

TechieJeff

    Newbie

  • Members
  • Pip
  • 8 posts
Hello CodeCall,

I have recently begun programing in C. I purchased a VTC video tutorial to help me out along the way. Well, to make a long story short, i've gathered myself that C++ is more useful than C.

By continuing to learn c, in the hopes that one day I may 'master' the language, would I be able to easily 'upgrade' to c++ without much difficulty? I am aware that some statements are different, such as instead of printf in c, in c++ it is cout, but how different is the language from C?

I apologize for my ignorance, I'm very new to programming. To be honest, its only been a few days (watching anti-trust was my inspiration).

I appreciate all comments and feedback, thank you!

Jeff

#2
Walle

Walle

    Learning Programmer

  • Members
  • PipPipPip
  • 75 posts
I am in no way an expert on either language, but these are my reflections:

The biggest difference is not in the syntax, but it is that c is not object oriented, c++ is. So, it's very important to understand what an 'object' is, how to treat objects, e.t.c. You basicly have to think different.

That said, my experience is that c++ accept c-style in a widely manner (for example, using "printf" in c++ is completely legal, taken that the appropriate header is included.) It's easy to move from c to c++, once you fully understand the idea behind OOP.
________________________________________________
"I'm not young enough to know everything." - Oscar Wilde

#3
WingedPanther

WingedPanther

    A spammer's worst nightmare

  • Moderators
  • 16,831 posts
Almost all C programs are also valid C++ programs (with poor style, of course). C++ is a more flexible language, but that comes with a certain amount of additional complexity. Most operating systems are programmed in C, as are most drivers (along with assembly). Learning C will not be a wasted effort. I prefer C++, myself. That's primarily a style thing, and the fact that I like OOP coding.
Programming is a branch of mathematics.
My CodeCall Blog | My Personal Blog