COSC 135 B Programming Assignment 1
Due Monday 9-18-00

You may work with one partner on this assignment and turn in one copy of your team's work.

  1. Write a program that takes as input a number of kilometers, and displays the corresponding number of nautical miles. Your source code should be well commented and contained in a file named Miles.java. Turn in your code (just the Miles.mcp or Miles.java file) by placing it in your folder, inside the handin folder on the G:\ drive. Use the FahrenheitToCentigrade.java file as a guide. Note that
  2. Write a program that takes as input a number of pennies, nickels, dimes and quarters (all assumed to be integers) and displays the corresponding number of dollars and change. For example, 6 pennies, 8 nickels, 12 dimes, and 6 quarters would be 3 dollars and 16 cents. By this Wednesday, hand in a paper with a picture of your GUI design and a simple description of what your code will do. Again, the FahrenheitToCentrigade.java file can serve as a template. Your source code should be in a file called PiggyBank.java (or a codewarrior project file with PiggyBank.java included in it).