Question: Write a method named SavingsCalculator that takes two double arguments and one integer argument named principle, rate, and years respectively, and computes and returns the
Write a method named SavingsCalculator that takes two double arguments and one integer argument named principle, rate, and years respectively, and computes and returns the amount on deposit based on the values passed. The method shoud return the amount on deposit as a double type. Assume the formula for amount on deposit with interest is principle rateyears Call the above SavingsCalculator from main by passing values for principle, rate, and years input by the user. Print the returned amount on deposit in the main.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
