Create a new folder in your student folder on the T: drive named
HW4 and copy a blank Program.java to the
HW4 folder.
To see how your homework should finally look run my version by
double clicking on My Computer and going to the folder
T:/Harcourt/Spring2009/CS140/HW4 and then double
click on the file run.bat.
Finish our clock program by adding a minute hand to the clock. (See the demo above). Make the clock have a gray background and make sure the minute and second hands are different colors. Use good programming practice and break up your code into methods. For example, one obvious choice is to put the code that causes the second hand to make one complete revolution in its own method named one_minute.
You'll notice that as the second hand revolves it will erase the minute hand, so you need to be careful to redraw the minute hand when it gets erased by the second hand.