1. Why should the classes you design be as general as possible? 2. Consult the documentation for the class JFrame in the Java Class Library. a. From which class does JFrame inherit the method pack? b....


1. Why should the classes you design be as general as possible?


2. Consult the documentation for the class JFrame in the Java Class Library.


a. From which class does JFrame inherit the method pack?


b. What four constants can you pass to the method setDefaultCloseOperation?


3. Write statements that will draw three squares side by side. First, draw the leftmost square using the current pen color.


Next, draw the middle square in blue. Finally, draw the rightmost square using the same color as the leftmost square.



May 18, 2022
SOLUTION.PDF

Get Answer To This Question

Submit New Assignment

Copy and Paste Your Assignment Here