home *** CD-ROM | disk | FTP | other *** search
- * This program takes the following user inputs:
- * Principle -> R19
- * Yearly interest rate -> R18
- * # of compunds/year -> R17
- * # of years -> R16
- * and returns the amount of money accured
- *
- * The formula is:
- * A = P(1 + r/n)^nt
- * A = R19*( 1 + R18 / R17) ^ R17*R16
- :Begin
- WD Welcome to the Compound Interest Calculator!
- WD Enter your principle
- RD r19
- WD Enter the yearly interest rate
- RD r18
- WD Enter the number of compounds per year
- RD r17
- WD Enter the number of years your principle is invested
- RD r16
- * R15 will have the power to raise to
- MOV r15, r17
- MUL r15, r16
- * R14 will have the base adder
- MOV r14, r18
- DIV r14, r17
- * R13 will have the base quantity
- MOV r13, 1
- ADD r13, r14
- POW r13,r15
- mul r19, r13
- WD Your amount at this rate will be:
- WD r19