Question: 4.23 (Calculating the Compound Interest with Integers) Modify the program of Fig. 4.6 so that it uses only integers to calculate the compound interest. [Hint:
4.23 (Calculating the Compound Interest with Integers) Modify the program of Fig. 4.6 so that it uses only integers to calculate the compound interest. [Hint: Treat all monetary amounts as inte- gral numbers of pennies. Then "break" the result into its dollar portion and cents portion by using the division and remainder operations, respectively. Insert a period.] 4.23 (Calculating the Compound Interest with Integers) Modify the program of Fig. 4.6 so that it uses only integers to calculate the compound interest. [Hint: Treat all monetary amounts as inte- gral numbers of pennies. Then "break" the result into its dollar portion and cents portion by using the division and remainder operations, respectively. Insert a period.]
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
