Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Hi, I need to write a code in Java to predict the growth of a bank account due to compounded interest. Using of formula I
Hi, I need to write a code in Java to predict the growth of a bank account due to compounded interest. Using of formula
I = Bold * R Bnew = Bold + I where R = Periodic interest rate (a percentage: for example, 10% is 0.1) I = Interest Bold = current balance, before compounding Bnew = current balance, after compounding
be deducted from the account at the end of each period if the current balance is less than the threshold.) Afterwards, allow the user to specify the initial account balance, the annual interest rate, and the period at which interest is compounded (monthly, quarterly, or yearly). Then let the user select one of two options: (A) specify the length of the investment (in the same units as specified for the compounding period), and have the program compute the final account balance, or (B) specify a goal for the account balance, and have the program calculate how long (in the same units as the compounding period) it will take to achieve that amount. For both options, in addition to the final result, give the user the option to request a table describing the account balance at the end of each period. After displaying the final result, ask the user whether they want to do another calculation (with the same processing charge and threshold). If they choose to do that, then ask for all the information again (except for the processing charge and threshold). If they choose not to do another calculation, then ask the user if they want to try a different processing charge and threshold. If they do, then ask them for those two inputs and repeat the whole process for any number of calculations. Otherwise, stop the program. Calculations: Use these formulas for computing the interest and the new balance at the end of each period: I=BoldRBnow=Bold+I where R= Periodic interest rate (a percentage: for example, 10% is 0.1 ) I= Interest Bold= current balance, before compounding Bnuw= current balance, after compounding (WARNING: These formulas are NOT in Java, and you may NOT use single letter variable names except for loop control variables. Use descriptive names, and avoid obscure abbreviations.)Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started