INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Jobs

Difference between C, C+, C++

Difference between C, C+, C++

(OP)
I am new to this, my background is electromechanical and gas turbines.  I just started learning PLC's and getting pretty comfortable with it.  My compatriots recommended I take C programming but I don't know the differences.  They also said since I have a full-time job I need to buy one of those CD programs for self study.  Can someone give me some guidance on what direction to go?  THANKS

RE: Difference between C, C+, C++

C is a general programming language.  Small compiler, lots of free compilers.  Quite easy to learn once you get the hang of the syntax.  It is available on almost every platform you can think of.  Note that there are 3 main variants of C: K&R, C89 and C99.  Most compilers are C89.

C++ is an Object Oriented variant of C.  If you are going the C++ route, don't learn C first: you'll get into a lot of bad habits.  However, it is a big language with lots of new concepts.  If you are intending to write GUIs, this is probably the way to go.  It is not available on as many platforms as C.  There is a standard library of algorithms STL which does all the standard stuff like linked lists, vectors etc.  There are lots of free compilers about.

C# is a Microsoft Language.  It is big, slow, still being developed and a very bad excuse for a faster processor.  You can download the Express version from the microsoft site or get the CDs for £3.  Don't try it on a system less than 1GHz 256Mb.  It is XP based but will work on 2000.  It is not a good first language.

RE: Difference between C, C+, C++

Forgot to answer the actual question: which direction you should go?  It really depends on what you intend to do with it.  

If you are going to stick to engineering type programs and programming controllers, stay with C.  Lots of C experts out there if you have any questions.

If you are going into developing GUIs or stuff for Mobile Phones, try C++.  You can develop GUIs in C too but it is easier in C++ in that each control is an object.  Some people use C++ like a lazy variant of C i.e. they use // for comments and make declarations all over the place: not just at the top of the routine.  All C++ compilers will compile C.  Lots of C++ experts in cyberspace if you get stuck.

If you wish to be tied to Microsoft and .net, torture yourself and have to change compilers every year or so, you could try C#.  Most people are still learning C#: it is only about 4 years old.  I'd wait another two years before trying C# - it is like Visual Basic when it started.  A new compiler is released every year with new features and it is just too much for carbon based lifeforms.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources


Close Box

Join Eng-Tips® Today!

Join your peers on the Internet's largest technical engineering professional community.
It's easy to join and it's free.

Here's Why Members Love Eng-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close