Check03E (TS = 15)

Download the jar file typex.jar (the file has been updated on October 5, 10:00am) and save it in the same directory as type.jar. typex.jar should already be part of your CLASSPATH.

Create the program named Check03E that prompts the user to enter the annual interest rate, the current amount, and period. Then it computes the future value of the amount.

The annual interest is a double. You may assume that the user always enters a double greater than or equal to -100 and smaller than or equal to 100. The current amount is a double. You may assume that the user always enters a double greater than or equal to 0. The period is an integer. You may assume that the user always enters an integer greater than 0.

Print the results as in the following three sample runs. The input provided by the user is typeset in boldface.

Annual interest rate (percentage): 1.5
Current amount (dollars): 250
Period (years): 2
Future amount (dollars): 257.56
Annual interest rate (percentage): -3
Current amount (dollars): 1.50
Period (years): 3
Future amount (dollars): 1.37
Annual interest rate (percentage): 1.0512
Current amount (dollars): 1.00
Period (years): 1
Future amount (dollars): 1.01

To check whether your code is correct, you can use eCheck. You are advised to use the offline mode first. Once your code is correct (worth 3 marks) and you are happy with your style (worth 2 marks), you can switch to the online mode and submit your solution. For style, you should adhere to the code conventions described in Appendix C of the textbook.