REM	INDIVIDUAL RETIREMENT ACCOUNT EARNINGS PROGRAM

REM

REM

REM	Prepared by: [You]	Date: [Today's Date]

REM

REM	Version: Original	File Name: IRA.BAS

REM

REM	This program prepares an Individual Retirement Account Earnings Report

REM	given the starting and ending years of an account, the annual contribution,

REM	and the interest rate.

REM

REM

REM	STARTUP:

REM

CLS	'CLEAR THE SCREEN

LET BALANCE = 0

LET INTEREST = 0

LET FORMAT$ = "#### $$#,### $$#,###.## $$###,###.##"

REM

REM	INPUT DATA:

REM

LOCATE 8, 15

PRINT "IRA EARNINGS CALCULATION:"

LOCATE 10, 15

INPUT "Enter the starting year: ", START.YEAR

LOCATE 11, 15

INPUT "Enter the retirement year: ", END.YEAR

LOCATE 12, 15

INPUT "Enter the annual IRA contribution: $", CONTRIBUTION

LOCATE 13, 15

INPUT "Enter the annual % interest: ", RATE

LOCATE 13, 57

PRINT "%"

LOCATE 15, 15

INPUT "Enter your full name for the report: ", STUDENT$

REM

REM	PRINT REPORT:

REM

LPRINT : LPRINT : LPRINT

LPRINT TAB(10); "INDIVIDUAL RETIREMENT ACCOUNT EARNINGS REPORT"

LPRINT : LPRINT

LPRINT TAB(10); "FOR: "; TAB(16); STUDENT$

LPRINT

LPRINT TAB(10); STRING$(48, "-")

LPRINT TAB(10); "YEAR"; TAB(17); "CONTRIBUTION";

LPRINT TAB(33); "INTEREST"; TAB(49); "BALANCE"

LPRINT TAB(10); STRING$(48, "-")

LPRINT

FOR YEAR = START.YEAR TO END.YEAR

LET BALANCE = BALANCE + CONTRIBUTION

LET INTEREST = BALANCE * RATE / 100

LET BALANCE = BALANCE + INTEREST

LPRINT TAB(10); USING FORMAT$; YEAR; CONTRIBUTION; INTEREST; BALANCE

NEXT YEAR

LPRINT CHR$(12)	'EJECT PAGE FROM PRINTER

END