Enhance the ButtonViewer1 program so that it prints the date and time at which the button was clicked. Hint: System.out.println(new java.util.Date()) prints the current date and time.
Implement the ClickListener in the ButtonViewer2 program of Section 10.2.2 as a regular class (that is, not an inner class). Hint: Store a reference to the label. Add a constructor to the listener class that sets the reference.
Add error handling to the program in Section 10.3.2. If the interest rate is not a floating-point number, or if it less than 0, display an error message, using a JOption Pane (see Special Topic 2.5).
Write a graphical application simulating a bank account. Supply text fields and but- tons for depositing and withdrawing money, and for displaying the current balance in a label.
Write a graphical application describing an earthquake, as in Section 3.3. Supply a text field and button for entering the strength of the earthquake. Display the earth- quake description in a label.
Write a graphical application for computing statistics of a data set. Supply a text field and button for adding floating-point values, and display the current minimum, maximum, and average in a label.
Write an application with three labeled text fields, one each for the initial amount of a savings account, the annual interest rate, and the number of years. Add a button "Calculate" and a read-only text area to display the balance of the savings account after the end of each year.
In the application from Exercise P10.12, replace the text area with a bar chart that shows the balance after the end of each year.