C Programming in Mac OS X

Programming C in Mac OS X requires you to install Xcode. Fortunately, this development tool is available free. Go to your App Store and search for Xcode. Install Xcode by clicking on " Free " or " Install ". Please note that the installation will take quite some time. There are two methods of writing and compiling a C program. The first method is using Xcode and the second method is using command line. Both methods require installation of Xcode. Using Command Line To use command line to compile a C program, we need to enable gcc (or llvm-gcc). Under Xcode, select Xcode >> Preferences , click on the Downloads tab. You should see a line " Command Line Tools ". Click on the install button on the right. Close Xcode when you are done. You can use TextEdit to create a simple C program. Alternatively, you can also use vim from the Terminal. Open the Terminal and navigate to the folder you would like to store the program. C...