Sitenotice: 11/29/2018: The wiki is back. It turns out, some anti-virus product on my web server had an issue with the latest version of PHP. My server techs have resolved this issue, and things should be working again. During the investigation, I did restore to a backup from September. There is a chance that any changes done since then were lost, but I do not recall any edits. --OS-9 Al

8/30/2016: Massive re-work is being done on the InfoBox Templates. Read that page to keep up with the plan for that, and adding better keyword tags (categories) to all the pages. --OS-9 Al (talk) 15:28, 31 August 2016 (CDT)

AMORTIZE

From CoCopedia - The Tandy/Radio Shack Color Computer Wiki
Jump to: navigation, search
100 TP=0: TI=0: T$="
110 CLS: PRINT@5,"AMORTIZATION SCHEDULE"
120 PRINT@64,"ENTER PRINCIPAL";: INPUT P$
130 IF (VAL(P$)>0) AND (VAL(P$)<10000000) THEN P=VAL(P$): GOTO150
140 PRINT@80,": GOTO120
150 PRINT@97,"INTEREST RATE (% /YR)"; : INPUT I$
160 IF (VAL(I$)>O) AND (VAL(I$)<91) THEN I=VAL(I$)/100: GOTO180
170 PRINT@117,"": GOTO150
180 PRINT@129,"NUMBER OF MONTHS";: INPUT N$
190 IF (VAL(N$)>0) AND (VAL(N$)<500) THEN N=VAL(N$): GOTO210
200 PRINT@147,": GOTO180
210 PRINT@161,"MONTHLY PAYMENT";: INPUT R$
220 IF (VAL(R$)>0) AND (VAL(R$)<10000) THEN R=VAL(R$): GOTO240
230 PRINT@178,": GOTO210
240 PRINT@193,"BALLOON PAYMENT";: INPUT B$
250 IF (VAL(B$)>=0) AND (VAL(B$)<1000000) THEN B=VAL(B$): GOTO270
260 PRINT@210,"": GOTO240
270 PRINT@225,"TO PRINTER (Y OR N)";: INPUT PR$
280 IF NOT (PR$="Y" OR PR$="N") THEN PRINT@245,"": GOTO270
290 GOSUB590
300 IF PR$<>"Y" THEN 370
320 LPRINT TAB(5)"AMORTIZATION SCHEDULE"
340 LPRINT TAB(8)"TO       TO"
360 LPRINT "MONTH PRINC.   INTER.   BALANCE"
370 FOR T=1 TO N
380 WI=P*(I/12): TI=TI+WI
390 WP=R-WI: TP=TP+WP: P=P+WI-R
400 N$=STR$(T): L=LEN(N$)
410 PRINT@P1+4-L,N$;
420 IF PR$="Y" THEN LPRINT TAB(4-L)N$;
430 C=INT(WP*100): P2=10: GOSUB630
440 C=INT(WI*100): P2=19: GOSUB630
450 C=INT(P*100): P2=29: GOSUB630
460 IF P1<416 THEN P1=P1+32: GOTO510
470 IF T=N THEN 510
480 PRINT@448,"PRESS ANY KEY TO CONTINUE";: B$=INKEY$
490 IF B$="" THEN 480
500 GOSUB590
510 NEXT T
520 PRINT@P1,"TOTL";
530 IF PR$="Y" THEN LPRINT "TOTL";
540 C=INT(TP*100): P2=10: GOSUB630
550 C=INT(TI*100): P2=19: T$="Y": GOSUB630
560 PRINT@460,"PRESS R TO RESTART";: B$=INKEY$
570 IF B$="R" THEN 100
580 GOTO560
590 CLS: PRINT@5,"AMORTIZATION SCHEDULE"
600 PRINT@40,"TO": PRINT@49,"TO"
610 PRINT@64,"MONTH PRINC.   INTER.   BALANCE"
620 P1=96: RETURN
630 C$=STR$(C): L=LEN(C$)
640 PRINT@P1+P2-(L-2),LEFT$(C$,L-2)+"."+RIGHT$(C$,2);
650 IF PR$<>"Y" THEN 710
660 IF (P2<>29) AND (T$<>"Y") THEN 700
660 LPRINT TAB(P2-(L-2))LEFT$(CS,L-2)+"."+RIGHT$(C$,2): GOTO710
700 LPRINT TAB(P2-(L-2))LEFT$(C$,L-2)+"."+RIGHT$(C$,2);
710 RETURN