C Programming on Your Laptop

There are several options for supporting a C programming environment on your laptop:

  1. If your computer is running Linux:
    You most likely already have gcc, gdb and emacs installed, and you should be set.

  2. If you are using a Mac:
    Open a free apple developer account.
    Download and install the Xcode package that includes gcc from here, if you have the latest version of Mac OS X.
    Or, for older versions of Mac OS X, go to https://connect.apple.com, click on "downloads", then on "developer tools" on the right, and download and install the appropriate Xcode package for your OS version.
    Unless you already have emacs installed on your Mac, go to http://www.aquamacs.org and install Aquamacs, which is an emacs editor for Mac.
    See Emacs command summary for tips on using Emacs.

  3. If you are using a PC:
    Your first option is to use Cygwin, which is a Linux-like environment for windows.
    Go to http://www.cygwin.com and click on 'Install Cygwin now', located in the upper right corner of the page.
    Once downloading completes, double click setup.exe to run the setup.
    Choose 'www.mirrorservice.org' for the mirror site.
    Under 'Setup', choose Devel -> gcc-core, gcc-g++ and gdb, and click on 'Skip' next to these items to undo the skip option and install these and the associated files (which will get selected automatically).
    Repeat this for Editors -> xemacs and xemacs-sumo.
    The rest of the installation involves leaving the default options and clicking 'next'.
    Note that the installation process could take a while.
    When your installation is complete, you should be able to double click on the Cygwin icon to start Cygwin, and then type 'xemacs &' to run xemacs.
    See Emacs command summary for tips on using Emacs (or Xemacs).

  4. Alternative options:
    If you are using a PC, and are familiar with the Microsoft Visual Studio environment, you may prefer to use it instead. See Using Visual Studio for Simple C Programs for more details.
    If you are a fan of the