Java -> C++? How difficult will that be?

Discussion in 'OT Technology' started by ProdigyDub, Apr 22, 2004.

  1. ProdigyDub

    ProdigyDub The greatest trick the devil ever pulled

    Joined:
    Jun 24, 2003
    Messages:
    2,414
    Likes Received:
    0
    Location:
    UT Austin
    I'm getting to the point where I can write pretty intermediate, non-trivial, efficient Java programs with relative ease.

    My question is just, given that I'm gonna have to start on C++ soon (which I have slight experience in but NOTHING substantial), will the "switch" be much at all? I really don't know that much at all about C++ itself, but I'm assuming experience with OOP and general algorithmic/problem solving skills i've developed from Java will make the transition ...not so bad?

    Sorry if this kinda thing has been posted before but I couldn't find the info I needed. Thanks in advance.
     
  2. sam758

    sam758 OT Supporter

    Joined:
    Aug 26, 2003
    Messages:
    901
    Likes Received:
    0
    c++ has a lot more "features" than java, such as pointers, consts, templates(if you haven't used the new java1.5sdk), manual memory management, and some others i can't remember on the top of my head. if you only wanted to use c++ for relatively simple projects then you wouldn't necessarily have to learn how to use all of the new features.
    you'd want to learn the important features such as pointers because it's really easy to screw up pointers and get bugs that are impossible to find.
    in terms of oop, c++ is basically the same as java as long as you don't deal with multiple inheritance and multiple inheritance levels(i.e. try doing super.super.func() in java).
    in terms of general algorithm programming, only difference is that you can do functional programming in c++, i.e. you never have to create any objects.
    if you wanna read up on c++, c++ primer plus by prata is pretty good.
    hope that helps.
     
  3. Penguin Man

    Penguin Man Protect Your Digital Liberties

    Joined:
    Apr 27, 2002
    Messages:
    21,696
    Likes Received:
    0
    Location:
    Edmonton, AB
    Shouldn't be too tough to switch, it's mainly a matter of learning the new syntax and getting used to some differences in memory management and such. Algorithmic skills should transfer straight over (as they should with any language).
     
  4. ProdigyDub

    ProdigyDub The greatest trick the devil ever pulled

    Joined:
    Jun 24, 2003
    Messages:
    2,414
    Likes Received:
    0
    Location:
    UT Austin
    Thanks to both you guys :)
     

Share This Page