/*A program to find compound interest*/ #include #include /*Declare variables*/ float balance, rate, future, years; main() { /*Have the user input the values desired*/ /* for the presetnt balance, rate, and time*/ printf("\nEnter the opening balance: "); scanf("%f",&balance); printf("\nEnter the interest rate in percent per year: "); scanf("%f",&rate); printf("\nEnter the number of years the balance is held: "); scanf("%f",&years); /*Calculate the future balance using the formula*/ future = balance * (pow(2.7183,(rate/100)*years)); /*Print the results*/ printf("\nThe future balance is %f, future); }