CS 5JA, Winter 2009
Assignment 1 - Getting Started

This assignment is intended to help you get started with Java programming and CS 5JA. Although you are not required to write any original Java source code, you must carry out some steps that are common to all programming assignments. These "hurdles" include (1) using an editor to create a file that contains Java source code; (2) using the Java compiler to translate this source code to bytecode; (3) launching the Java Virtual Machine to execute this bytecode; and (4) using our online turnin program to turn in your files.

You may perform these activities on any computer on which the Java Development Kit (JDK), version 5.0 or higher, is installed. Instructions for using the JDK by itself are given below. If you choose to use a program such as netBeans or BlueJ to compile and execute, you must learn how to use such programs on your own. All CS 5JA students are authorized to use the computers in the Instructional Computing labs. The turnin program can be used from any computer with Internet access and a web browser.

Due: Wednesday, January 14, 9:00 pm
Worth: 50 homework points

  1. Type in (or copy and paste) the following Java application, and save it as a plain text file called Start5JA.java (or just download it here).
  2. Compile the program to produce Start5JA.class, and execute it to verify that it works.
  3. Turn in Start5JA.java and Start5JA.class here before the deadline.
  4. NOT FOR CREDIT: do all of the text's Chapter 1 exercises (pp. 32-34), and Exercises 2.1 through 2.23 from Chapter 2 (pp. 65-69). Do not turn in these results, but do save them to help you study for exams.

Updated 1/2/09, by C. Michael Costanzo