DOWNLOADING AND INSTALLING DrRacket

NOTE: These directions apply to version 5.1.1.  They
will likely apply to subsequent versions as well; 
just replace the 5.1.1s with the current version number.
If this changes, please let me know so I can update
these directions.


DOWNLOADING
1. Go to http://www.racket-lang.org/.
2. Click "Download Racket".
3. Select your operating system, then click the Download button.
4. Choose a location from which to download.  The University of
   Utah seems pretty good for this purpose.
5. Save the file wherever it is convenient.


INSTALLING
1. Execute the file you downloaded.  On Windows, it is
   racket-5.1.1-bin-i386-win32.exe.  On a Mac, it is a
   disk image such as racket-5.1.1-bin-i386-osx-mac.dmg.
2. You will be prompted for where you want to put Racket.
   On Windows, C:\Program Files\Racket is typical.
   On the Mac, put the Racket folder into the Applications
   folder.

That's it!  You can now run Racket on your computer.


RUNNING FOR THE FIRST TIME
When you open DrRacket for the first time, you will notice that
the window is split into halves.  The top half is the Definitions
window, the bottom half is the Interactions Window.  If the
Interactions Window indicates that a programming language must
be chosen, then do the following:

1. Select Language --> Choose Language.
2. Select "Use the language declared in the source" and click OK.
3. Verify that the following line of code is now in the Definitions
   window:

      #lang racket

4. Click Run at the top right of DrRacket.  You will notice
   that the purple text at the bottom that told you to choose a
   language has gone away.

If you are in the AP CS class, your installation is done.  
If you are in the Programming Concepts class, you need to add
the Simply Scheme additions (below).


SIMPLY SCHEME ADDITIONS (Not needed for AP CS)

There are two pieces to this: setting up so that the core Simply Scheme
procedures work and installing additional files for homework and projects.
The second of these is best done with an FTP client.  I recommend FileZilla and the instructions will be based on that.  Any FTP client
will do if you have something else you prefer.

Core Simply Scheme Installation
1. On the line after #lang racket, enter:

      (require (planet dyoo/simply-scheme:1:2/simply-scheme))

2. Click Run at the top right of DrRacket.  This will download
   and install the special files needed for the Simply Scheme book.
   This may take a minute or two to complete.
3. Quit DrRacket completely.
4. Start DrRacket again.
5. Select Language --> Choose Language.
6. Select Simply Scheme and click OK.
7. Click Run and you should see that the language is Simply Scheme
   in the Interactions window.

Once you are done doing this, every subsequent time that you
use DrRacket, all of the Simply Scheme stuff will work automatically.

Special Files Installation

1. Download and install FileZilla.
2. Open FileZilla.
3. In the box labelled "Host" (top left corner), enter "ftp.cs.berkeley.edu"
   (without the quotes) and press ENTER (or click Quickconnect at top right corner).
   On the left, you will see contents on your machine; on the right, you will see
   folders on UC-Berkeley's FTP site.
4. In the left window, find and open the Racket folder on your machine.  Typically
   this would be under C:\Program Files on Windws or /Applications on the Mac OS.
5. In the right window, double-click on the "pub" folder on UC-Berkeley's site.
6. Scroll down on UC-Berkeley's site until you see the folder called "scheme".
   Drag the "scheme" folder from UC-Berkeley's site into your Racket folder.

When you come across a problem which demands that you use "functions.scm",
"ttt.scm", "match.scm", etc., you can use the "load" procedure to access the
necessary file.  For example, chapter 2 uses the Functions program, so you would
type:

   (load "scheme/functions.scm")

On the Mac, you may have to type the absolute pathname:

   (load "/Applications/Racket v5.1.1/scheme/functions.scm")

(I am trying to figure out what the issue is surrounding pathnames on the Mac;
I will update this once I figure it out.)

Now the Functions program (and all other stuff in "functions.scm" will be
accessible in your session.

The following is stale.  Note to self: update once random number stuff is sorted out.  
NOTE: If you want to use random numbers, edit your "simply.scm" file and remove 
(or comment out) the code for random number generation.  DrScheme's random does what 
you want.  "simply.scm" won't be very random.