Thread: Another question about C programming for the absolute beginner

  1. #1
    Registered User
    Join Date
    Dec 2006
    Posts
    12

    Another question about C programming for the absolute beginner

    Is C programming for the absolute beginner good for someone who say wants to learn C++ but wants to start off with C?

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    If your ultimate goal is C++, then there isn't a lot of point in learning C as a stepping stone.

    Some programming concepts are so fundamentally different that some people consider learning C first to be a negative step from not knowing anything at all.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  3. #3
    Registered User
    Join Date
    Dec 2006
    Posts
    12
    Quote Originally Posted by Salem
    If your ultimate goal is C++, then there isn't a lot of point in learning C as a stepping stone.

    Some programming concepts are so fundamentally different that some people consider learning C first to be a negative step from not knowing anything at all.
    Alright. do you have a sugestion for learning C++???

  4. #4
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  5. #5
    Registered User
    Join Date
    Dec 2006
    Posts
    12
    OK thank you. Do you think that Torque is a good game engine to start with?

  6. #6
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    I thought you wanted to learn C++?
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  7. #7
    Registered User
    Join Date
    Dec 2006
    Posts
    12
    Quote Originally Posted by Salem
    I thought you wanted to learn C++?
    I do, don't you get the C++ source code when you buy the indie liscence for Torque Game Engine? if so doesn't that mean you can use C++ with it?

  8. #8
    MFC killed my cat! manutd's Avatar
    Join Date
    Sep 2006
    Location
    Boston, Massachusetts
    Posts
    870
    1) Learn basic C++ programs. <- You are here.
    2) Start on more advanced C++ command-line programs.
    3) Learn GUI.
    4) Start looking at game programming.
    Silence is better than unmeaning words.
    - Pythagoras
    My blog

  9. #9
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    > I do, don't you get the C++ source code when you buy the indie liscence for Torque Game Engine?
    But if you ever hope to do more than tinker with the edges, then you'll need to put the 6 months to a year's hard graft into actually learning the language properly.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  10. #10
    Registered User
    Join Date
    Dec 2006
    Posts
    11
    Hi, guys. I actually approached learning C++ through first studying C. From my own perspective, it did help. But basing from experience, and I know most of you guys agree, learning C/C++ or any language depends on the learning material you have at hand. There's about thousands of tutorials and books about them. You just have to find one you're most comfortable going through.

    For me personally, I like those that teaches me as if speaking to a 12 year old. Who cares. I find it more effective, specially to someone like me who came from med school and has absolutely no programming background.

    I've encountered some books and tutorials on C++ but requires that you have some, even thorough, knowledge of C. If you wanna study C first because you have time and you're patient enough and you're not in a hurry, then wouldn't that be better?

  11. #11
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Ireland
    Posts
    8,446
    Quote Originally Posted by lasher
    I've encountered some books and tutorials on C++ but requires that you have some, even thorough, knowledge of C.
    Can you give some examples? You must be confusing something here. That is simply not possible. A tutorial or teaching book in C++ that requires you to be knowledgeable about C is a tutorial or teaching book you must throw in the garbage. It's no good.

    However, you may have heard of teaching C++ aimed at C programmers. But that is totally different. The aim is to teach C++ for those that are already knowledgeable about C, and not to imply C is needed in order to learn C++.

    Quote Originally Posted by lasher
    I actually approached learning C++ through first studying C. From my own perspective, it did help.
    Some people say that C helped them learning C++. Fair enough. But what if I tell you Visual Basic helped me learn C++, and Pascal helped me learn Delphi, which in turn also helped me learn C++. And that BASIC helped me learn Pascal and that....

    C alone didn't help you or anyone else. That is the impression we get. C++, like any other programming language, is much easier to learn if we have prior programming experience. Just that.
    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

  12. #12
    In the Land of Diddly-Doo g4j31a5's Avatar
    Join Date
    Jul 2006
    Posts
    476
    >> C alone didn't help you or anyone else. That is the impression we get. C++, like any other programming language, is much easier to learn if we have prior programming experience. Just that.

    But it's another story if you spend too much time with that other programming language. You will have a difficult time adjusting to C++'s way of thinking.

    E.g: Try programming A LOT with Visual Basic. Then try C++. You'll be confused even learning about pointers.

  13. #13
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Ireland
    Posts
    8,446
    Oh.... I programmed a lot with visual basic, trust me on this one. And I didn't feel the least daunted by C++. There are of course some concepts that are harder to understand on any language. It's the same with any science, some parts of it are easier than others. In C++ it was in fact references that took me a long while to shift my mind to. Not so much pointers.

    C++ References are little devils disguised as sweet innocent little children with big smiles. You think they are easy with that syntax of them? Mwahahah [/evil laughter]

    However, what does really affect you learning process is language paradigms. Visual Basic is no different from C++ with the exception of generic programming and guess what... bang! that's where I feel less comfortable. I still battle to put this damn thing inside my head.

    Someone that programmed for years and years in Haskell will not shift to C++ without a lot of pain. And someone who has been programming all their life in procedural languages will get an heart-attack if shifting to Haskell.
    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

  14. #14
    Registered User
    Join Date
    Jan 2005
    Posts
    7,366
    >> If you wanna study C first because you have time and you're patient enough and you're not in a hurry, then wouldn't that be better?

    No. If you have time and you're patient enough and you have good learning materials, then learning C before C++ won't be a bad thing. But it won't be a good thing either. While C++ includes virtually all of C, it also has much higher-level constructs and features available to accomplish goals. Learning the lower-level versions in C often make it harder to adjust to the higher level mindset best used in C++.

    For example, you learn pointers in C, and you make think this helps you in C++. Instead, it makes you feel more comfortable with pointers and makes it harder for you to use the higher-level constructs in C++ like references, container classes, smart pointers, etc. If you learn C++ from the start (with good C++ learning material which can be hard to find) then you will learn to use references, container classes and smart pointers first. Then after you are comfortable with those you can dig deeper into the lower level details that C exposes.

  15. #15
    Registered User
    Join Date
    Dec 2006
    Posts
    11
    Well, we all have our own experiences... But probably it's wiser for us to learn from those who have been there or have a lot more experience.

    But for my own little experience, my very first introduction to programming was HTML, then some Javascript (w/c was my intro to C-like language), then an attempt on Visual Basic (w/c I found quiet confusing bec. of the absence of the braces and parenthesis), so I decided on C (w/c I didn't finish actually coz my goal was C++), and now I'm clawing my way to enlightenment with C++. I like C++, and I heard they pay higher for C/C++ programmers than to VB -- oops!

    But anyway, I'm finding it more effective to not dwell on only one or two references but to gather as many books or websites as I can. Bec. at times that I encounter some difficult concepts, I look it up on other books or resources. Authors have different styles of teaching. For my learning pace, I find some to be effective and some not.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Same old beginner question...
    By Sharmz in forum C Programming
    Replies: 15
    Last Post: 08-04-2008, 11:48 AM
  2. Beginner: Linked List question
    By WeatherMan in forum C++ Programming
    Replies: 2
    Last Post: 04-03-2008, 07:16 AM
  3. Quick IF statement question (beginner)
    By jim.rattlehead in forum C Programming
    Replies: 23
    Last Post: 11-29-2007, 06:51 AM
  4. A very beginner question!
    By sifeet in forum C Programming
    Replies: 8
    Last Post: 11-06-2007, 07:13 AM
  5. Beginner on Win32 apps, lame question.
    By Templario in forum C Programming
    Replies: 3
    Last Post: 11-06-2002, 08:39 PM