C Programming in Mac OS X
![Image](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiH4XOBO3LrjQwhb7e-BKfzRSB-ZT1zXuwmzezzNcGnEPrcmoXW8tfnJJf4IsIXqKIhapoDQUI53uoKvHGGQdhdIx_E_5seLyaPcoP-8wH9j0YN1k6ww3_MhDLxHXy4yX4Bg7xMGhjI8qE/s400/Screen+Shot+2013-07-01+at+2.30.37+PM.png)
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