CSC 220: Homework 1

Out: Tuesday, 4 September 2001
Due: Thursday, 13 September 2001

Goals
To exercise the student's knowledge of Java and the development environment. To review arrays, strings, and string input and output. To provide a starting point for the next assignment, where arrays will be replaced by Linked Lists.

Assignment:
Write a Java program (command line application, not an applet) which prompts the user for strings and enters them in an array. After each line of entry, the program prints the entire array of strings. Exit when the user types the single character input ".".

Example Run of Program:

 java RememberStringsTest 
  Enter strings to remember. Exit program with input "."
  ? Hello
  Hello
  ? World
  Hello
  World
  ? Good night
  Hello 
  World
  Good night
  ? .
  Bye.

Notes on Homework submission

Homework is due midnight of the due date. Home is submitted by placing it in the proper subdirectory of your home directory off your class account. Make the directory "submissions" and a subdirectory for each homework assignment "hw1", "hw2", and so on. Obey case: all small letters. Unlike Microsoft file systems, Unix names are case sensitive. "HW1" and "hw1" are two different names.

Here is how you might create these directories:

[burt@lee burt]$ mkdir submissions
[burt@lee burt]$ cd submissions
[burt@lee submissions]$ mkdir hw1
[burt@lee submissions]$ cd hw1
[burt@lee hw1]$ pwd
/big/rhome/burt/submissions/hw1
[burt@lee hw1]$ 
If you work from home, ssh to the lab and use sftp to transfer your work into this directory.

Notes of Computer Use

Read http://www.cs.miami.edu/~irina/password.html about password policy. Change your password immediately!

Read http://www.cs.miami.edu/~irina/how_to_login.html about how to install and use SSH. Note that you can also install ssh faster using the instructions given on the Syllabus.

TA's will pick up the homeworks directly from your submissions/hw1 directory. We do this by assuming your user identity. We can do this because of an entry in your .rhosts file. Do not change your .rhosts file, or this will break and we will not be able to pickup your homework. This is also your notification that we can assume your identity, for purposes of picking up your homework, and by your invitation, helping you debug your programs remotely.