CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 9 of 9
  1. #1
    Join Date
    Apr 2009
    Posts
    3

    Java, C++, and C#

    Yes, yet another comparison thread. I googled and found lots of comparison charts, but I don't know any programming terms, so they were kind of useless to me. Could someone explain the pros and cons of these three in layman's terms?

  2. #2
    Join Date
    Jan 2006
    Location
    Singapore
    Posts
    6,765

    Re: Java, C++, and C#

    What are the general requirements of the program that you intend to develop?
    C + C++ Compiler: MinGW port of GCC
    Build + Version Control System: SCons + Bazaar

    Look up a C/C++ Reference and learn How To Ask Questions The Smart Way
    Kindly rate my posts if you found them useful

  3. #3
    Join Date
    Apr 2009
    Posts
    3

    Re: Java, C++, and C#

    I don't know yet.

  4. #4
    Arjay's Avatar
    Arjay is offline Moderator / EX MS MVP Power Poster
    Join Date
    Aug 2004
    Posts
    13,490

    Re: Java, C++, and C#

    Do you know how to program in any of the three?

  5. #5
    Join Date
    Apr 2009
    Posts
    3

    Re: Java, C++, and C#

    Quote Originally Posted by Arjay View Post
    Do you know how to program in any of the three?
    I don't know any programming terms
    I hope that answers your question.

  6. #6
    Join Date
    Dec 2005
    Location
    England
    Posts
    86

    Re: Java, C++, and C#

    C++ is very low-level. You have to do your own memory-management and stuff (by default; there do exist garbage-collectors for C++, but they're not much used) and worry about the low-level implementation details of everything you write. It's mostly compiled to native code, although there is a .NET compiler for it, or a dialect of it, known as ‘Managed C++’. It's not very portable (when native). It's quite popular, though, and has some fairly good libraries to abstract away some of the tedium and non-portability. It is primarily an object-oriented extension to C, but that extension is, well, extensive, and even more has been built on top of it. It is mostly compatible with C: in general, valid C is also valid C++, and you can use C code natively in C++ (which is handy, since many many things use C, including all current popular operating systems).

    Java is kind of like C++, but vastly simplified: it features garbage collection and some other stuff, and you're unlikely to have to fiddle with the low-level stuff involved in working with C++. It has a reputation for being slow, which is mostly undeserved these days, but it's still a bit slower than C++. It runs on the Java virtual machine rather than targetting native code, so you can (on the whole: some things aren't portable) run the same application on Linux, Windows, or OS X, for example, without recompiling or rewriting. However, it lacks some features of C++, like multiple inheritance and operator overloading, and its ‘generics’ are, I believe, less powerful than C++'s equivalent ‘templates’. It forces an OO coding style, at least insofar as possible.

    C# is Microsoft's answer to Java, although, unusually, the specification is open and a free implementation exists as part of the Mono open .NET platform. It has, on the whole, more features and flexibility than Java, and it's gaining in popularity, although Java is currently still in the lead. It tries to bridge both worlds, giving the safety of Java by default but the low-level power of C++ when necessary. It also attempts to force OO coding.

  7. #7
    Join Date
    Feb 2009
    Posts
    56

    Re: Java, C++, and C#

    Whatever language you use, it belongs to the same root.

    For example, 2 languages C++ and C#, you might support C# today, but some time later you discover its buggy warnings/errors you have to choose C++ for your projects
    Remember that those warnings and errors are generated not really by your own faults. Whatever you opt to use, you are still a programmer of programming language!

  8. #8
    Join Date
    Sep 2007
    Posts
    62

    Re: Java, C++, and C#

    Might also want to check out :

    An Introduction to Microsoft F#

  9. #9
    Join Date
    Oct 2002
    Location
    Germany
    Posts
    6,205

    Re: Java, C++, and C#

    [ redirected ]

    Regards,
    Siddhartha

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured