Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

BlueJ programming. This is a form of java programming. Has to run in BlueJ. Please and thank you! This lab assignment builds on using methods

image text in transcribed
image text in transcribedBlueJ programming. This is a form of java programming. Has to run in BlueJ. Please and thank you!
This lab assignment builds on using methods to simplify programming problems Instructions 1. Create a class called InvestmentCalculator. It will have both a main method and a local?thod called future!nvestmentvalue Before soving on to the next step, be sure to code the main method header 2. Isplement and test futureInvestmentValue method. The futureInvestmentValue method computes the future investment value given an investment amount, an annual percentage interest rate, frequency of compounding (in months) and a specified number of years. The future value is determined based on the following formula futureValue investaentAmount (1+ monthlyInterestRate) For example, given: investmentA mount $1eee, annualPctRate = 3.25%, and numberOfYears 1, compounding 12 (monthly) the calculated futurevalue is $1,932.99. Use the following method header: static double futureInvestmentValue(double investmentAmount, double monthlyInterestRate, int numberOfYears, int compounded) (a) You will need to use the pow method in the Math class to do the power function. Its method header is: double Math pow(doublex,double y): (b)You also need to convert the annualPctRate to monthlyInterestRate by dividing the annualPctRate by 1208. You can test this method interactively through BlueJ. 3. Modify the main method so that it prompts the user to enter the investment amount (e.g. 1808), the annual percentage interest rate (e.g. 9%), Frequency of compounding, and a number of years (e.g 10) and writes output as shown below to both the terminal and to a file named "investment.txt". Page 1 of 2

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Design And Relational Theory Normal Forms And All That Jazz

Authors: Chris Date

1st Edition

1449328016, 978-1449328016

More Books

Students also viewed these Databases questions