setting up C++

Discussion in 'Software' started by sentinel, Mar 23, 2009.

  1. sentinel

    sentinel Private E-2

    I would like a few links, and advice on starting up with C++. As in, where i have to go, and what i have to download, any and all help would be nice, thanks.
     
  2. Senlis

    Senlis Staff Sergeant

    the thing to download would be c++ express edition from microsoft.
    http://www.microsoft.com/express/vc/
    that will give you the compiler and IDE you need. Other than that, I would recommend purchasing a good C++ book.
     
  3. sentinel

    sentinel Private E-2

    Anything you would recommend, in the way of a good C++ book?
     
  4. Senlis

    Senlis Staff Sergeant

    When I was in school, I used books from Deitel I believe. When I get off work, I'll see if I can look it up.
     
  5. smilinggeek

    smilinggeek Private E-2

    Depends what OS you're using, although not so much if you use a true cross-platform IDE (Integrated Design Environment).

    The compiler I use is GCC. Command line based, text files to edit, it's what I prefer as it lets me just code rather than try to work around someone elses restrictions which is what you get when you use an IDE. Some people consider this to be "old school", and they're probably right. But it's a great way to learn C++ without all the cruft imposed by most IDE. Once you've learned C++, then you can move on to an appropriate IDE. On the other hand, if you already know what environment you'll be using later, it can't hurt to learn that one from the start along with the language.

    If you want some sort of IDE there's a bunch of free choices:

    IBM provides Eclipse. Multi-platform. Has lots of people who really like it. Lots of people who don't. Can always give it a try: www.eclipse.org
    See this article: http://www.ibm.com/developerworks/opensource/library/os-eclipse-stlcdt/index.html

    Codeblocks provides a free IDE. Haven't heard much about it:
    http://www.codeblocks.org/

    Netbeans isn't just for Java anymore:
    http://www.netbeans.org/features/cpp/index.html

    There are a few others. Personally, I would stay away by what's provided by Microsoft, unless you're absolutely sure you never want to do any cross-platform work and will only ever program for the MS Windows platform, in which case you really should use their stuff. Unfortunately, Microsoft has a nasty habit of changing standards to suit themselves as part of their continuing "embrace, extend, extinguish" campaign. I've known several programmers from the Microsoft world who got quite lost when trying to program multi-platform, because Microsoft tools had made them do things in ways that are just plain wrong anywhere else. So be very wary of Microsoft tools unless you intend to program only for Microsoft. This is my opinion. Others will probably differ.

    The main question you need to ask is "what are my goals in learning C++"? Are you going to be working in a particular environment, in which case you should choose the development tools most common to that environment. Or do you just want to learn the basics, in which case I recommend going for text files and compilers so that you get comfortable with what's happening. Or are you trying to learn OO concepts and ideas but still be able to use your extensive C knowledge? All that will affect what development environment you might choose.

    As for books, can't go wrong with "C++ In a Nutshell" from O'Reilly as a good reference, and I liked the "C++ Primer" by Lippman/Lajoie/Moo. The book "Accellerated C++" by Koenig&Moo is also a must-have. I also use the "STL Tutorial and Reference Guide" by Musser/Derge/Saini to learn more about the standard template library.

    Good luck.
     
    Last edited: Mar 23, 2009
  6. sentinel

    sentinel Private E-2

    I just want to learn the basics, right now. The people ive talked to said i should either learn C++, or C#, and have heard bad things about C#, although i think it might be biased.

    Is C++ different from VC++, and C++.net
     
  7. smilinggeek

    smilinggeek Private E-2

    It's not so much C++ vs C# (C-sharp), it's Java vs C#. C# has very little in common with C++. Microsoft's description was apparently: 70% Java, 5% Visual Basic, 10% C++, 15% New. In other words, you shouldn't compare C++ and C#, you should compare Java and C#. C++ is a different language with different design goals and different strengths and weaknesses.

    My opinion (if it matters) is that C# is a proprietary language owned and controlled by Microsoft. It's Microsoft's version of Java that they had to create as they were not able to "embrace, extend, extinguish" Java itself (and Microsoft paid dearly - almost $2 billion in penalties - for their attempt at doing so by abusing their monopoly). They now claim C# is "open", but a big chunk of C# is patented .NET stuff, and you can't have one without the other. So again, if you use C#, you're dependent on Microsoft for everything. If you're programming in open-source or environments where the use of documented, un-patented standards are required, C# doesn't cut it.

    So if you want or need to learn C++, go ahead. Many projects use it, it's an incredibly useful language, and it's not going to go away anytime soon. If the types of projects you need to work on require C#, note that it's a different language with different design goals. However, if that's what you need, then go ahead and learn that.

    As for generic C++ vs VisualC++ or C++.net, it's up to you. Just note that anytime you start to use Microsoft products, their one and only goal is to lock you into using their products. Their versions of doing things is different, and is geared to making sure that people continue to use their products. So again, if all you're going to be programming in is Microsoft environments, then use Microsoft tools (and keep paying them for it). However if you have any intention of working on non-Microsoft ways of doing things, then keep to platform independent tools (ie: non-Microsoft) because otherwise your learning curve will be quite high when you realise there's more to the world of programming than what Microsoft claims.

    But invariably it comes down to the environment you intend to program for. Once your programming battlefield is selected, then your tools become more or less self-evident.

    Bah, post is too verbose, but I can't be arsed to shorten it. Edit as you wish.
     
  8. PC-XT

    PC-XT Master Sergeant

    I like to use IDEs that are simple, but allow additions (like plugins) that can do some of the more complex or visual stuff more effeciently. I've used Quincy and Dev-C++.

    I also agree with smilinggeek's post re C# & C++.
     

MajorGeeks.Com Menu

Downloads All In One Tweaks \ Android \ Anti-Malware \ Anti-Virus \ Appearance \ Backup \ Browsers \ CD\DVD\Blu-Ray \ Covert Ops \ Drive Utilities \ Drivers \ Graphics \ Internet Tools \ Multimedia \ Networking \ Office Tools \ PC Games \ System Tools \ Mac/Apple/Ipad Downloads

Other News: Top Downloads \ News (Tech) \ Off Base (Other Websites News) \ Way Off Base (Offbeat Stories and Pics)

Social: Facebook \ YouTube \ Twitter \ Tumblr \ Pintrest \ RSS Feeds