# Write a program that calculates the final value of a ten year- \$10-000 (1).docx

D

Write a program that calculates the final value of a ten year, \$10,000 investment whose annual return gradually declines from 2% to 1% over that term. Solution //Header file section #include<iostream> using namespace std; //Program begins with a main function int main() { //Initialize variables double investment=10000, highIntrest=0.02,changeIntrest=0.01,years=10,result; //prompt output cout<<\"Year \"<<\"Final_value \"<<endl; //Calculate the final value of a ten year for(int i=1;i<=10;i++) { investment = (investment* highIntrest)+investment; highIntrest=changeIntrest; cout<<i<<\"Â Â Â Â  \"<<investment<<endl; } cout<<\"Final Value of a ten year=\"<<investment<<endl<<endl; //Pause the system for a while system(\"pause\"); return 0; } .

## Recommended

Write a SIMPLE java program to print out the numbers from 100 to 1- wi.docx by
Write a SIMPLE java program to print out the numbers from 100 to 1- wi.docxdrosa1
31 views2 slides
Write a simple c++ program that computes the value of ex by using the.docx by
Write a simple c++ program that computes the value of ex by using the.docxdrosa1
12 views1 slide
Write a short assembly language module to be used with C++ that rotate.docx by
Write a short assembly language module to be used with C++ that rotate.docxdrosa1
2 views2 slides
Write a short essay- between 400 and 500 words- responding to the assi.docx by
Write a short essay- between 400 and 500 words- responding to the assi.docxdrosa1
3 views1 slide
Write a SELECT statement that returns the LastName and JobTitle of eac.docx by
Write a SELECT statement that returns the LastName and JobTitle of eac.docxdrosa1
6 views1 slide
Write a recursive C function that counts the number of vowels in a str.docx by
Write a recursive C function that counts the number of vowels in a str.docxdrosa1
7 views2 slides

## More from drosa1

Write a recursive function to convert a character string of digits to.docx by
Write a recursive function to convert a character string of digits to.docxdrosa1
5 views2 slides
Write a query to display the customer last name and city for all custo.docx by
Write a query to display the customer last name and city for all custo.docxdrosa1
3 views2 slides
write a program that reads package weights and calculate the post fee.docx by
write a program that reads package weights and calculate the post fee.docxdrosa1
2 views2 slides
Write a program that takes an input of n and prints the numbers from 1.docx by
Write a program that takes an input of n and prints the numbers from 1.docxdrosa1
2 views2 slides
Write a program to compute the volume V of a cylinder of radius r and (1).docx by
Write a program to compute the volume V of a cylinder of radius r and (1).docxdrosa1
2 views1 slide
Write a program in assembly language that will test PIN #0 of PORTA to.docx by
Write a program in assembly language that will test PIN #0 of PORTA to.docxdrosa1
4 views2 slides

### More from drosa1(20)

Write a recursive function to convert a character string of digits to.docx by drosa1
Write a recursive function to convert a character string of digits to.docx
drosa15 views
Write a query to display the customer last name and city for all custo.docx by drosa1
Write a query to display the customer last name and city for all custo.docx
drosa13 views
write a program that reads package weights and calculate the post fee.docx by drosa1
write a program that reads package weights and calculate the post fee.docx
drosa12 views
Write a program that takes an input of n and prints the numbers from 1.docx by drosa1
Write a program that takes an input of n and prints the numbers from 1.docx
drosa12 views
Write a program to compute the volume V of a cylinder of radius r and (1).docx by drosa1
Write a program to compute the volume V of a cylinder of radius r and (1).docx
drosa12 views
Write a program in assembly language that will test PIN #0 of PORTA to.docx by drosa1
Write a program in assembly language that will test PIN #0 of PORTA to.docx
drosa14 views
Write a program that uses a dynamic array that contains 5 items of dou (1).docx by drosa1
Write a program that uses a dynamic array that contains 5 items of dou (1).docx
drosa12 views
Write a program that finds the temperature- as an integer - that is th.docx by drosa1
Write a program that finds the temperature- as an integer - that is th.docx
drosa12 views
Write a python program that opens the career-txt file that is included.docx by drosa1
Write a python program that opens the career-txt file that is included.docx
drosa12 views
Write a program that contains and utilizes a function called haltNum(i.docx by drosa1
Write a program that contains and utilizes a function called haltNum(i.docx
drosa12 views
Write a program in MATLAB to implement the algorithm of Gaussian Elimi.docx by drosa1
Write a program in MATLAB to implement the algorithm of Gaussian Elimi.docx
drosa13 views
write a program to calculate the average of six number input by the us.docx by drosa1
write a program to calculate the average of six number input by the us.docx
drosa17 views
Write a program that uses the DrawingPanel to produces the following f.docx by drosa1
Write a program that uses the DrawingPanel to produces the following f.docx
drosa12 views
Write a program in assembly language 8086 not 8085 to find the number.docx by drosa1
Write a program in assembly language 8086 not 8085 to find the number.docx
drosa17 views
write a mips code which pop-ups a confirmation dialog which have yes o.docx by drosa1
write a mips code which pop-ups a confirmation dialog which have yes o.docx
drosa110 views
Write a program in (C or C++ or Java or python) to capture the center.docx by drosa1
Write a program in (C or C++ or Java or python) to capture the center.docx
drosa12 views
write a new equation of the line in slope intercept form parallel to e.docx by drosa1
write a new equation of the line in slope intercept form parallel to e.docx
drosa15 views
Write a program file_max-c that reads a set of integer numbers from a.docx by drosa1
Write a program file_max-c that reads a set of integer numbers from a.docx
drosa13 views
Write a PHP function (write the function only) to dynamically create a.docx by drosa1
Write a PHP function (write the function only) to dynamically create a.docx
drosa13 views
Write a PASCAL program to compare two integers entered from the keyboa.docx by drosa1
Write a PASCAL program to compare two integers entered from the keyboa.docx
drosa155 views

Computer Introduction-Lecture06 by
Computer Introduction-Lecture06Dr. Mazin Mohamed alkathiri
117 views12 slides
EILO EXCURSION PROGRAMME 2023 by
EILO EXCURSION PROGRAMME 2023info33492
124 views40 slides
ICS3211_lecture 09_2023.pdf by
ICS3211_lecture 09_2023.pdfVanessa Camilleri
126 views10 slides
Pharmaceutical Inorganic chemistry UNIT-V Radiopharmaceutical.pptx by
Pharmaceutical Inorganic chemistry UNIT-V Radiopharmaceutical.pptxMs. Pooja Bhandare
120 views51 slides
BÀI TẬP BỔ TRỢ ﻿TIẾNG ANH FAMILY AND FRIENDS NATIONAL EDITION - LỚP 4 (CÓ FIL... by
BÀI TẬP BỔ TRỢ ﻿TIẾNG ANH FAMILY AND FRIENDS NATIONAL EDITION - LỚP 4 (CÓ FIL...Nguyen Thanh Tu Collection
58 views252 slides
11.28.23 Social Capital and Social Exclusion.pptx by
11.28.23 Social Capital and Social Exclusion.pptxmary850239
383 views25 slides

EILO EXCURSION PROGRAMME 2023 by info33492
EILO EXCURSION PROGRAMME 2023
info33492124 views
Pharmaceutical Inorganic chemistry UNIT-V Radiopharmaceutical.pptx by Ms. Pooja Bhandare
Ms. Pooja Bhandare120 views
BÀI TẬP BỔ TRỢ ﻿TIẾNG ANH FAMILY AND FRIENDS NATIONAL EDITION - LỚP 4 (CÓ FIL... by Nguyen Thanh Tu Collection
BÀI TẬP BỔ TRỢ ﻿TIẾNG ANH FAMILY AND FRIENDS NATIONAL EDITION - LỚP 4 (CÓ FIL...
11.28.23 Social Capital and Social Exclusion.pptx by mary850239
11.28.23 Social Capital and Social Exclusion.pptx
mary850239383 views
Class 9 lesson plans by TARIQ KHAN
Class 9 lesson plans
TARIQ KHAN53 views
ISO/IEC 27001 and ISO/IEC 27005: Managing AI Risks Effectively by PECB
ISO/IEC 27001 and ISO/IEC 27005: Managing AI Risks Effectively
PECB 651 views
A-Level Art by WestHatch
A-Level Art
WestHatch48 views
Monthly Information Session for MV Asterix (November) by Esquimalt MFRC
Monthly Information Session for MV Asterix (November)
Esquimalt MFRC91 views
Classification of crude drugs.pptx by GayatriPatra14
Classification of crude drugs.pptx
GayatriPatra14104 views
Create a Structure in VBNet.pptx by Breach_P
Create a Structure in VBNet.pptx
Breach_P80 views
EIT-Digital_Spohrer_AI_Intro 20231128 v1.pptx by ISSIP
EIT-Digital_Spohrer_AI_Intro 20231128 v1.pptx
ISSIP407 views

### Write a program that calculates the final value of a ten year- \$10-000 (1).docx

• 1. Write a program that calculates the final value of a ten year, \$10,000 investment whose annual return gradually declines from 2% to 1% over that term. Solution //Header file section #include<iostream> using namespace std; //Program begins with a main function int main() { //Initialize variables double investment=10000, highIntrest=0.02,changeIntrest=0.01,years=10,result; //prompt output cout<<"Year "<<"Final_value "<<endl; //Calculate the final value of a ten year for(int i=1;i<=10;i++) { investment = (investment* highIntrest)+investment; highIntrest=changeIntrest; cout<<i<<"Â Â Â Â "<<investment<<endl; } cout<<"Final Value of a ten year="<<investment<<endl<<endl; //Pause the system for a while system("pause"); return 0; }
Current LanguageEnglish
Español
Portugues
Français
Deutsche