Can't make up my mind on which to learn C or C++

Discussion in 'Programming' started by BaconSubPancakes, Jun 11, 2018.

?

C or C++ Which should I learn?

  1. C

    3 vote(s)
    11.1%
  2. C++

    24 vote(s)
    88.9%
  1. Obviously this is tough for me, I am leaning towards C but C++ is good for more video game and design type applications, compared to C which is its parent language and does all around. Which do I do?
     
  2. Where's the both option :(
     
    • Agree Agree x 3
    • Like Like x 1
  3. Close your eyes and imagine yourself 1 year from now are you a game developer or a general application developer what do you like to do create fancy graphics or doing a more technical company software, are you an mobile app developer? then open your eyes then start learning.
     
  4. C is a very, very basic language. Much of what you do you have to do on your own, such as memory management and dynamically allocating space in memory for custom structures, arrays, etc. I'm not sure if C++ is the same way or not, but learning both wouldn't be a bad idea (as you typically learn C through a CS degree anyways)
     
  5. C++ is definitely the more confusing language, at least for me. I find C very pragmatic and straightforward.
     
  6. A good developer is someone who can build a desired piece of software, no matter the language. If C is the best for the job, go with that. If C++ is better for this job, do that instead. The idea of programming doesn't change across languages. Syntax changes, as well as maybe the orientation of the language.
     
  7. It really depends on you. For most purposes C++ is better than C.
    From StackExchange:
    If you meet any of those criteria, proceed with learning C.

    Otherwise, let me advise you against using C++. It is a complete mess. Some guy thought "Oh, C is cool. OOP is cool. Let's bolt OOP to C!".
    It was a bad idea.
    Regardless, C++ became popular. People used C++. That C++ needs to be maintained. And here we are.

    Coming from a Java background, you will find C++ too un-restrictive. It lets you shoot yourself in the foot, and the hand, and the face, and the stomach and lots and lots of other bodily organs.

    Sure, it offers a ton of flexibility, and that's great and all, but for 99% of cases, it's unnecessary. Instead, I suggest you learn a comparable but far more enjoyable language like Rust.

    If you really cannot be persuaded out of using C++, then yeah, C++ is the better choice.
     
  8. If you want to create create games C++ is the way(you can use Unreal Engine 4)
     
  9. I learnt C first ( while already having loads of experience with Java) and I gotta say: "Ooh boy, I freaking hate C". While it opens new ways to think in your mind, I hate coding in it. Nonetheless, knowing C gave me many advantages when I started learning C++. C++ was a peace of cake after already having the knowledge about C and Java.

    But I gotta say, when I learnt C++, my mind was blown, in a good way. The way C++ lets you do everything you want is ... I can't tell you how amazed I am by C++ in words. It litterally blew my mind, it restructured the way I started thinking about how programming languages work etc. ( Although I gotta say that by that time I learnt how to code in assembly too so that also restructured my mind.)

    I thought I loved Java until I learnt C++. Java sucks ass in comparision to C++. Although C++ still has it flaws...
    Anyway, this is my opinion and people have different opinions. Good luck.
     
  10. I prefer C, and C++ is a mess, but from a personal marketability perspective, learn C++.

    (I've been an embedded software engineer for the past 38 years.)
     
  11. C++ is complete and utter bullshit, and fuck everyone and everything trying to "defend" it. C is the simplest language out there, and the "scary" memory management is so easy you must be a moron not to manage to do it. Each malloc needs a free. It's that simple. C also has the simplest data structure out there, with the best features so far. Sure, traits or something alike would be nice, but it's not that bad still. Use a vtable and be good to go. If you are unable to use C properly, C++ will not be any easier. C++ is so bloated, unmaintainable, and shitty overall, it's not even comparable to Windows and the NT kernel. C++ has, what, 7 ways to cast? Are you joking? OOP is also a burning ship where every user is literally this dog:
    [​IMG]
    The entirety of OOP is flawed, and it ends up in code impossible to read, write, use, and maintain. C(99) is and will for a very long while be the absolute best programming language there is, with other competitors coming close (e.g. Rust). My only tip for you is to stay far, far away from C++.
     
    • Like Like x 1
    • Agree Agree x 1
  12. Why don't you tell us how you really feel.

    Without arguing whether you're correct or not, the fact is if you want a job in software engineering, you better know OOP and C++.
     
  13. i just love this post
     
  14. Get the best of both world with java :D
     
  15. Depends on what you want to do. A good way to think of the differences (this is a generalization, so you hardcores dont rant on me here) is C is for embeded systems (has little ram/cpu) and C++ is for desktop systems (much higher ram/cpu). Example, a router vs a PC.
     
  16. I've been doing embedded systems (radar systems on aircraft) for over 30 years, and all our new systems are using C++ with Wind River, for better or worse.
     
  17. Even with the generalization clause. ^_^

    Yes yes yes. Some embedded system can use C++ just as much as some desktop programs can use C. They even have stripped down versions of C++ specially designed for embedded systems. C is still the leader where ram/cpu is limited or critical, so I'm surprised something as critical as aircraft radar is using C++.

    https://www.quora.com/Why-is-C-used-rather-than-C++-in-embedded-systems
     
  18. Things have changed a lot in the past several years. Yeah, your Tamagotchi is limited on memory, but the systems we're putting in aircraft have multi-gigabytes of RAM now. Besides, C++ doesn't use much more than C for the program storage,* although C++ does like a large heap for creating all those objects. And heaven help you if you run out of heap space.

    Even smaller systems have lots of RAM now. Hell, there are parking meters running Java! I don't think Java is known for being stingy on memory use.

    * My rule of thumb for C is 10 bytes per line of code. Never got around to checking it C++, but even if it was double that, it's quite reasonable.
     
  19. Not because C++ is complicated it means it cannot be learn or that it is bad. I also don't understand this huge disaster on how complex it is: I know just basic C++ and I think that it's totally understandable
     
  20. Yeah, I know C++, and the complexity is one of my smallest concerns with OOP and the STL in the picture; it is still a dumpsterfire.
     

Share This Page