Skip to main content

Posts

Showing posts with the label Starting with C

Getting Started with C or C++

On MAC : Source : [ http://www.cprogramming.com/xcode.html ] Using Apple XCode Once you've downloaded XCode, you can install it from the disk image. Then you can run XCode from Developer|Applications|XCode. XCode has lots of documentation and can walk you through setting up a project. The very simplest thing to do is to create a new project from "File|New Project...". First choose "Application" and then "Command Line Tool". This will give you a basic command line program that you can use when you're learning to program. Before you leave that screen, make sure to change the "Type" of the project to "C++ stdc++" if you are using C++ instead of C. Go through the rest of the prompts and create your new project. Now you have a small project set up that has a main.cpp file. You can edit main.cpp, but by default it will include a small sample "hello world" program. Let's go ahead and run that sample progra