Question

In: Computer Science

2.29 Domain Lab 4.1 -- Compound Interest Calculator Compound Interest Calculator Your program should ask the...

2.29 Domain Lab 4.1 -- Compound Interest Calculator Compound Interest Calculator Your program should ask the user (in this order) for: Principal … In this equation, it is expressed as PV Annual Interest Rate Time Period (years) … Note that there are 12 compounding periods per year. So your n value in the equation is years multiplied by 12 Your program should then calculate and display: Total Interest Generated Total Future Value SPECIAL NOTE Make sure to round output to 2 decimal places!

Solutions

Expert Solution

//in C language

//importing header files
#include <stdio.h>
#include <math.h>
//main function
int main()
{
float PV, Interest_rate, year, CompInterest;

//tacking imput principle from user
printf("Enter principle : ");
scanf("%f", &PV);
//tacking imput time in years from user
printf("Enter time in years: ");
scanf("%f", &year);
//tacking imput rateinterest from user
printf("Enter rate: ");
scanf("%f", &Interest_rate);
  
// equation for calculating compound interest
CompInterest = PV* (pow ((1 + (Interest_rate / (12.0*100.0))), year*12));

// displaying the result
printf("Result Compound Interest = %.2f", CompInterest);
return 0;
}

------------------------------------------------------------------------------------------------------------------

#in python language

principle_Amount=float(input("Enter amount:"))
time=int(input("Enter time:"))
rate=float(input("Enter Rate:"))
CI=principle_Amount*pow((1+(rate/(12*100))),time*12)
print(CI)


Related Solutions

COMPOUND INTEREST/YIELD CALCULATIONS For this question, use the compound interest calculator found at investor.gov Assume you...
COMPOUND INTEREST/YIELD CALCULATIONS For this question, use the compound interest calculator found at investor.gov Assume you saved $10,000 and hope to invest it in a manner which would allow you to afford the down payment on a home that cost $250,000. On top of the $10,000 initial investment from your savings, you will invest $250 each month from your salary. You hope to purchase the home in ten years and plan to invest in a “safe” investment yielding between 3-7%...
Integer value calculator: Write a program using C++ that acts as a calculator. The program should...
Integer value calculator: Write a program using C++ that acts as a calculator. The program should ask the user for two numbers and an operator. Then the program must print the result using the two input values and the operator. Prompts and input requirements. Ask the user for two integer values and a value that indicates the operation. Likely you will want to choose the normal operators: + - * / %. Output Requirements: Make your output easy to understand,...
Using the Queue ADT: Create a program that uses a Queue. Your program should ask the...
Using the Queue ADT: Create a program that uses a Queue. Your program should ask the user to input a few lines of text and then outputs strings in same order of entry. (use of the library ArrayDeque) In Java please.
Using the Stack ADT: Create a program that uses a stack. Your program should ask the...
Using the Stack ADT: Create a program that uses a stack. Your program should ask the user to input a few lines of text and then outputs strings in reverse order of entry. (Optional) Create a similar program that uses a stack. Your new program should ask the user to input a line of text and then it should print out the line of text in reverse. To do this your application should use a stack of Character. In Java...
2.20 Domain Lab 3.1 -- Velocity Calculator You may (or may not) need the following constants:...
2.20 Domain Lab 3.1 -- Velocity Calculator You may (or may not) need the following constants: Pi = 3.14 Speed of Light (c) = .307 parsecs/year Gravity (g) = 9.81 m/s squared Velocity Calculator Your program should ask the user (in this order) for: Initial Velocity Acceleration A Time Period Your program should then calculate and display the resulting final velocity based on the inputs provided.
2. Using the Stack ADT: Create a program that uses a stack. Your program should ask...
2. Using the Stack ADT: Create a program that uses a stack. Your program should ask the user to input a few lines of text and then outputs strings in reverse order of entry. In Java please.
Write a program that acts as a basic calculator Assume the starting result is 0 Ask...
Write a program that acts as a basic calculator Assume the starting result is 0 Ask the user for the operation to be performed 0 – Exit 1 – Add 2 – Subtract 3 – Multiply 4 – Divide (Assume input will not be 0) Keep on performing the operation and showing the result until the user inputs the ‘0’ (exit) operation. You need to have everything written as functions E.g. - You should only have the options listed once...
Enhance your program from Exercise 20 by continuing to ask the user for the interest rate...
Enhance your program from Exercise 20 by continuing to ask the user for the interest rate and loan amount. Then ask the user for the amount of principle they would like to payoff each month. Make sure that the user enters a positive number that is less than the loan amount. This means that the monthly payment will change from month to month. Use this information to produce a payment chart that will include as output the Payment (Month) Number,...
1. Calculate the compound amount. Use the compound amount formula and a calculator. (Round your answer...
1. Calculate the compound amount. Use the compound amount formula and a calculator. (Round your answer to two decimal places.) P = $1700, r = 5% compounded semiannually, t = 12 years 2. Calculate the future value. (Round your answer to two decimal places.) P = $8000, r = 5.5% compounded quarterly, t = 3 years 3.Calculate the future value. (Round your answer to two decimal places.) P = $29,000, r = 8% compounded monthly, t = 5 years
Business Applications. Find the present value (principal) or the compound interest, as indicated. Use a calculator...
Business Applications. Find the present value (principal) or the compound interest, as indicated. Use a calculator or Table 16-1 or Table 16-2 to find FVF or PVF. Round answers to the nearest cent. show entire solution please. 16. Bill Starnes needs to buy another used logging truck. His mother will loan him part of the money at 3% compounded quarterly. If Bill estimates that he will be able to repay his mother a total of $30,000 in 2 1/2 years,...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT