example programfuture value let' close the with one more example of the programming process in action we want to develop program to determine the future value of an investment we'll start with an analysis of the problem you know that money deposited in bank account earns interestand this interest accumulates as the years pass how much will an account be worth ten years from nowobviouslyit depends on how much money we start with (the principaland how much interest the account earns given the principal and the interest ratea program should be able to calculate the value of the investment ten years into the future we continue by developing the exact specifications for the program rememberthis is description of what the program will do what exactly should the inputs bewe need the user to enter the initial amount to investthe principal we will also need some indication of how much interest the account earns this depends both on the interest rate and how often the interest is compounded one simple way of handling this is to have the user enter an annual percentage rate whatever the actual interest rate and compounding frequencythe annual rate tells us how much the investment accrues in one year if the annual interest is %then $ investment will grow to $ in one year' time how should the user represent an annual rate of %there are number of reasonable choices let' assume the user supplies decimalso the rate would be entered as this leads us to the following specificationprogram future value inputs principal the amount of money being invested in dollars apr the annual percentage rate expressed as decimal number output the value of the investment years into the future relationship value after one year is given by principal( aprthis formula needs to be applied times next we design an algorithm for the program we'll use pseudocodeso that we can formulate our ideas without worrying about all the rules of python given our specificationthe algorithm seems straightforward print an introduction input the amount of the principal (principalinput the annual percentage rate (aprrepeat timesprincipal principal ( aproutput the value of principal