Homework Exercises of Java2D