Note: Mac-OS typically comes installed with Java
(including the compiler). If this is not the case,
you may have to install the Java Development Kit (JDK).
How will you know? If the javac command
fails (see below), then it's likely that you don't have JDK
installed.
A summary of the steps for edit-compile-test,
assuming JDK is installed on your Mac:
- Open a Terminal window and use Unix commands in it.
- Make new sub-directory (folder) if needed. Else
navigate there.
- Edit using pico.
- Compile at the command-line.
- Execute at the command-line.
- Transfer your files to the server using Fetch
or sftp.
Note:
- The Edit-Compile-Test inside a terminal
Window is exactly the same as on a Unix server
these instructions
(for the edit-compile-test part, not the SSH part).
- However, your home machine will possibly have different
folder names.
- You can create a new folder off of the desktop called
cs1111 and put everything in sub-folders under there.
Opening a terminal
- Step 1: Go to the search icon (top right corner)
and type terminal. This opens a terminal window.
- Step 2: When the terminal window opens,
you will most likely be just outside the Desktop,
so type cd Desktop.
- Step 3: If needed, make a cs1111
folder, then another testfolder underneath.
- Step 4: Navigate there and run pico.
- Step 5: Edit, compile and execute as
on a Unix machine.