Finish adding random walk code and fix many compiler errors.