Google
 

Trailing-Edge - PDP-10 Archives - decus_20tap1_198111 - decus/20-0020/bnkpro.bnk
There are 2 other files named bnkpro.bnk in the archive. Click here to see a list.
2' NAME--BANKPROJ
4'
6' DESCRIPTION--PROJECTS 8 BALANCE SHEET AND INCOME STATEMENT
7' ENTRIES FOR A BANK 10 YEARS INTO THE FUTURE.
8'
10' SOURCE--H.C. SIMPSON, REVISED 2/12/68
12'
14' INSTRUCTIONS--FOR EXPLANATORY NOTES ON THIS PROGRAM, SEE
15' PROJINF***
16'
18' THIS PROGRAM WAS WRITTEN FOR STUDENT USE AT AMOS TUCK SCHOOL
19' OF HANOVER, N.H., WHICH DOES NOT ASSUME RESPONSIBILITY FOR
20' ITS ACCURACY.
22'
24' * * * * * * * * * * * * MAIN PROGRAM * * * * * * * * * * * * 
26'
40PRINT TAB(20);"HANOVER BANK & TRUST CO."
45PRINT TAB(15);"PLANNING MODEL - FINANCIAL PROJECTION"
50PRINT
60PRINT
130 DIM T(50,11)
140 DIM O(25), N(25), P(25)
150DIM I(30)
170MAT T=ZER(50,11)
180 LET M=L1=X1=Y1=A2=J4=A4=A8=0
190 LET L9=T9=A=0
192 LET L4=L5=L7=0
195 REM LINES 200-696. TRENDS ARE CALCULATED IN SUB 5000 AND PROJECTED
196 REM FORWARD FOR 10 YEARS IN SUB 5200
200FORJ=1TO8
210GOSUB5000
220LETY(J)=R
225 LET Z(J)=INT(100*((G(1)-G(2))/G(2)))
240FORI=1TO10
250LETQ(I,J)=R1
260NEXTI
270NEXTJ
280LETK=A(0)=Y(1)
290LETJ=1
300GOSUB5200
310FORI=1TO10
320LETA(I)=S(I)
330NEXTI
340LETK=B(0)=Y(2)
350LETJ=2
360GOSUB5200
370FORI=1TO10
380LETB(I)=S(I)
390NEXTI
400LETK=C(0)=Y(3)
410LETJ=3
420GOSUB5200
425FORI=1TO10
430LETC(I)=S(I)
440NEXTI
450LETK=D(0)=Y(4)
460LETJ=4
470GOSUB5200
475FORI=1TO10
480LETD(I)=S(I)
485NEXTI
490LETK=E(0)=Y(5)
500LETJ=5
510GOSUB5200
520FORI=1TO10
530LETE(I)=S(I)
540NEXTI
550LETK=F(0)=Y(6)
560LETJ=6
570GOSUB5200
575FORI=1TO10
580LETF(I)=S(I)
585LETG(I)=0
590NEXTI
600LETK=G(0)=Y(7)
610LETJ=7
620GOSUB5200
630FORI=1TO10
640LETG(I)=S(I)
650NEXTI
660LETK=H(0)=Y(8)
670LETJ=8
675 GO SUB 5200
680FORI=1TO10
690LETH(I)=S(I)
695LETS(I)=0
696NEXTI
697 IF K1>0 THEN 1030
700 READ A2,D8,A8,E9,A4
705 READ M,A9,R3,A6
706 READ L8,L6
707 FORJ=1 TO 12
710 READ N(J)
712NEXTJ
713 FOR J=1 TO 12
720 READ O(J)
722 NEXT J
725 FOR J= 1 TO 12
730 READ P(J)
735 NEXT J
740 MAT READ R(10)
750 MAT READ U(10)
755 MAT READ V(10)
770 MAT READ X(10)
780 MAT READ I(30)
790 LET L6=L6/100
800 LET N(2)=N(2)/100
810 LET O(2)=O(2)/100
820 LET P(2)=P(2)/100
830 FOR I=1 TO 10
840 LET U(I)=U(I)/100
850 NEXT I
860 FOR I=1 TO 30
870 LET I(I)=I(I)/100
880 NEXT I
1000 DATA 8653,8639,9223,9456,10781
1001 DATA .1,.1,.1,.1,.1
1002 DATA 2236,2592,2902,2975,3623
1003 DATA 131,146,141,104,169
1004 DATA 1055,1173,1387,1373,1435
1005DATA 410,470,532,600,670
1006DATA200,300,400,500,600
1007 DATA 11,10,10,10,9
1008 DATA 2360,90
1009 DATA 68
1010 DATA 142,40
1011 DATA 1158
1012 DATA 1967
1013 DATA 2,36
1014 DATA 1800,4
1016 DATA 1648,6,400,200,200,100,100,100,800,0,0,0
1017 DATA 1590,4,100,100,100,100,100,100,100,100,100,100
1018 DATA 75,5,50,25,0,0,0,0,0,0,0,0
1019 DATA 5,5,5,5,5,5,5,5,5,5
1020 DATA 4.5,5,5,5,5,5,5,5,5,5
1021 DATA 0,0,0,0,0,0,0,0,0,0
1022 DATA 0,0,0,0,0,0,0,0,0,0
1024 DATA 6,6,6,6,6,6,6,6,6,6
1025 DATA 5,5,5,5,5,5,5,5,5,5
1026 DATA 8,8,8,8,8,8,8,8,8,8
1027 REM LINES 1031-1080. ROUNDS ANNUAL TRENDS
1028 FOR I=1 TO 10
1029 LET L9=I
1030 LET I=L9
1031 LET Z1=INT(100*Q(I,1)+.5)
1032 LET Z2=INT(100*Q(I,2)+.5)
1040 LET Z3=INT(100*Q(I,3)+.5)
1045 LET Z4=INT (100*Q(I,4)+.5)
1050 LET Z5=INT(100*Q(I,5)+.5)
1060 LET Z6=INT(100*Q(I,6)+.5)
1070 LET Z7=INT(100*Q(I,7)+.5)
1080 LET Z8=INT(100*Q(I,8)+.5)
1099 REM LINES 1100-1160 CALCULATED AND ROUNDS % BREAKDOWN OF PORTFOLIO
1100 LET P1=C(I-1)+D(I-1)+E(I-1)+N(1)+O(1)+P(1)+L8
1110 LET P2=INT(100*C(I-1)/P1+.5)/100
1120 LET P3=INT(100*D(I-1)/P1+.5)/100
1130 LET P4=INT(100*E(I-1)/P1+.5)/100
1140 LET P5=INT(100*N(1)/P1+.5)/100
1150LETP6=INT(100*O(1)/P1+.5)/100
1158 LET P8=INT(100*L8/P1+.5)/100
1160 LET  P7=INT(100*(1-P5-P6-P2-P3-P4-P8)+.5)
1170 LET D=I+10
1198 IF K1>0 THEN 1300
1199 PRINT
1200 PRINT"EARNING ASSETS BREAKDOWN AT THE END OF LAST YEAR AS FOLLOWS:"
1220 PRINT
1225 PRINT "ASSET NO","DESCRIPTION","PERCENT"
1230 PRINT"      1  ","GOV OBLIG",P5*100
1240 PRINT"      2  ","STATE & MUN",P6*100
1250 PRINT"      3  ","COM LOANS",P2*100
1260 PRINT"      4  ","R.E. LOANS",P3*100
1270 PRINT"      5  ","CONS LOANS",P4*100
1275 PRINT"      6  ","LIQUID LOANS",100*P8
1280 PRINT"      7  ","OTHER ASSETS",P7
1290 PRINT"             ","TOTAL      ","100"
1300 PRINT
1307 IF K1>0 THEN 1310
1308 IF I>1 THEN 1412
1310 PRINT"THE FOLLOWING TRENDS HAVE BEEN CALCULATED (ANNUAL % CHANGE):"
1315 PRINT
1320 PRINTTAB(0);"TREND NO";TAB(16);"DESCRIPTION";TAB(50);"5 YEAR TREND";
1321 PRINT TAB(65);A9
1330 PRINT TAB(6);"1";TAB(16);"DEMAND DEPOSITS";TAB(50);Z1;TAB (65);
1331 PRINT Z(1)
1340 PRINTTAB(6);"2";TAB(16);"TIME DEPOSITS";TAB(50);
1341 PRINT Z2;TAB(65);Z(2)
1350 PRINT TAB(6);"3";TAB(16);"COMMERCIAL LOANS";TAB(50);
1351 PRINT Z3;TAB(65);Z(3)
1360 PRINT TAB(6);"4";TAB(16);"REAL ESTATE LOANS";TAB(50);
1361 PRINT Z4;TAB(65);Z(4)
1370 PRINT TAB(6);"5";TAB(16);"CONSUMER LOANS";TAB(50);
1371 PRINT Z5;TAB(65);Z(5)
1380 PRINT TAB(6);"6";TAB(16);"COSTS EXCLUDING INTEREST";TAB(50);
1381 PRINT Z6;TAB(65);Z(6)
1390 PRINT TAB(6);"7";TAB(16);"INCOME EXCLUDING INTEREST";TAB(50);
1391PRINTZ7;TAB(65);Z(7)
1400 PRINT TAB(6);"8";TAB(16);"DEPRECIATION CLAIMED";TAB(50);
1401 PRINT Z8;TAB(65);Z(8)
1410 PRINT
1411 IF K1>0 THEN 1430
1412 PRINT
1415 PRINT"------------------------------------------------------------"
1416 PRINT
1417 PRINT
1420 PRINT TAB(20);"PROJECTION FOR YEAR"A9+I
1421 PRINT TAB(18);"*****************************"
1430 PRINT
1435 LET K1=0
1440 PRINT"DO YOU WISH TO CHANGE TRENDS?"
1442 PRINT"(NO=0,YES = NUMBER OF CHANGES)";
1450 INPUT K1
1460 IF K1=0 THEN 1490
1470 FOR J=1 TO K1
1475 PRINT"ENTER TREND NUMBER,NEW RATE";
1480 INPUT K2,K3
1485 LETQ(I,K2)=K3/100
1487 NEXT J
1488 GO TO 280
1490 PRINT
1491 LET L7=(L8-.5*L8)*L6
1492 PRINT"EARNING ASSETS ARE MATURING THIS YEAR IN THE AMOUNT OF:"
1493 PRINT TAB(12);"GOVERNMENT OBLIGATIONS";TAB(50);N(I+2)
1494 PRINT TAB(12);"STATE & POLITICAL OBLIGATIONS";TAB(50);O(I+2)
1495PRINT TAB(12);"OTHER INVESTMENTS";TAB(50);P(I+2)
1496 PRINT TAB(12);"LIQUIDITY LOANS";TAB(50);L8
1497 LET N(1)=N(1)-N(I+2)
1498 LET O(1)=O(1)-O(I+2)
1499 LET P(1)=P(1)-P(I+2)
1500 LET T(16,I)=(C(I-1)-C(I))+(D(I-1)-D(I))+(E(I-1)-E(I))+L8-L5
1502 IF T(16,I)>0 THEN 1508
1504 LET W(I)=-(.024*T(16,I))
1508 LET E9=E9+W(I)
1509 REM LINES 1510-2095.CALCULATES AND UPDATES ANNUAL STATEMENTS
1510 LET C1=(C(I)-.5*(C(I)-C(I-1)))*I(I)
1520 LET C2=(D(I)-.5*(D(I)-D(I-1)))*I(I+10)
1530 LET C3=(E(I)-.5*(E(I)-E(I-1)))*I(I+20)
1540 LET T(1,I)=C1+C2+C3+L7
1590 LET C4=(N(I)+.5*N(I+2))*N(2)
1600 LET C5=(O(1)+.5*N(I+2))*O(2)
1610 LET C6=(P(1)+.5*P(I+2))*P(2)
1620 LET T(2,I)=C4 +C5+C6+L1
1630 LET T(3,I)=G(I)
1640 LET T(4,I)=T(1,I)+T(2,I)+T(3,I)
1642 IF K5>0 THEN 1656
1644 PRINT
1646PRINT"ENTER AN ESTIMATE OF THE CHANGE IN AMOUNT OF CD'S ,AND AVERAGE"
1648 PRINT"RATE PAID DURING THE YEAR ON CD'S";
1650 INPUT D4,D5
1651 LET D5=D5/100
1652 LET D9=((D8+(D8+D4))/2)*D5
1654 LET D8=D8+D4
1656 LET T(5,I)=(B(I)-.5*(B(I)-B(I-1)))*U(I)+D9
1658 LET T(6,I)=F(I)
1660 LET T(7,I)=T(5,I)+T(6,I)
1662 LET T(8,I)=T(4,I)-T(7,I)
1690 LET D1=X1-Y1
1700 IF D1>1 THEN 1730
1710 LET D2=-D1
1720GOTO 1731
1730 LET D2=-(D1*.50)
1731 IF 25<T(8,I)-C5 THEN 1735
1732 LET  T(9,I)=(T(8,I)-C5)*.22+A
1733 GO TO 1736
1735 LET T(9,I)=(T(8,I)-C5-25)*.5+.22*25+A
1736 IF T(9,I)>0 THEN 1740
1737 LET A=A+T(9,I)
1738 LET T(9,I)=0
1740 IF 25<T(8,I)-W(I)-D2-C5 THEN 1770
1750 LET T=(T(8,I)-W(I)-D2-C5)*.22+T9
1760 GO TO 1780
1770 LET T=(T(8,I)-W(I)-D2-C5-25)*.5+.22*25+T9
1780 IF T>0 THEN 1784
1781 LET T9=T9+T
1782 LET T=0
1784 LET T(10,I)=T(8,I)-T(9,I)
1785 IF V(I)=0 THEN 1795
1790 LET T(11,I)=T(10,I)-W(I)-V(I)-X(I)+(T(9,I)-T)
1792 GOTO1797
1795 LET T(11,I)=T(10,I)-W(I)-X(I)+(T(9,I)-T)+X1+Y1
1797 LET T(12,I)=T(10,I)/R3
1800 LET T(13,I)=T(10,I)
1810 LET T(14,I)=H(I)-R(I)
1820 LET T(15,I)=N(I+2)+O(I+2)+P(I+2)-J4
1850 LET T(17,I)=B(I)-B(I-1)+D4
1860 LET T(18,I)=A(I)-A(I-1)
1862 GO TO 1870
1864 PRINT "ENTER NEW DIVIDEND PER SHARE";
1865 INPUT T4
1866 LET A6=T4*R3
1870 LET T(19,I)=-A6
1880 LET T(20,I)=T(13,I)+T(14,I)+T(15,I)+T(16,I)+T(17,I)+T(18,I)+T(19,I)
1890 LET T(21,I)=T(20,I)-.03*(B(I)-B(I-1)+D4)-.12*(A(I)-A(I-1))
1900 LET T(22,I)=T(22,I-1)+A2+T(20,I)
1920 LET T(23,I)=N(1)
1930 LET T(24,I)=O(1)
1935 LET T(25,I)=P(1)
1940 LET T(26,I)=C(I)+D(I)+E(I)+L5-E9
1960 LET T(27,I)=A8+T(27,I-1)+R(I)-H(I)
1970 LET T(28,I)=T(22,I)+T(24,I)+T(25,I)+T(26,I)+T(27,I)+T(23,I)
1980 LET T(29,I)=A(I)
1990 LET T(30,I)=B(I)+D8
1995 IF V(I)=0 THEN 2005
2000 LET T(32,I)=A4+T(32,I-1)+V(I)+X(I)
2001 GO TO 2010
2005 LET T(32,I)=A4+T(32,I-1)+X(I)+X1+Y1
2010 LET T(33,I)=M+T(33,I-1)+T(11,I)-A6
2020 LET T(31,I)=T(28,I)-T(29,I)-T(30,I)-T(32,I)-T(33,I)
2030 LET T(34,I)=T(28,I)
2040 LET T(35,I)=T(26,I)/(T(29,I)+T(30,I))
2050 LET T(36,I)=T(22,I)/(T(29,I)+T(30,I))
2060 LET T(37,I)=(T(28,I)-T(22,I)-T(23,I))/(T(33,I)+T(32,I))
2070 LET T(38,I)=(T(29,I)+T(30,I))/(T(33,I)+T(32,I))
2071 LET T8=0
2072 FOR J=4 TO 8
2076 LET T8=T8+O(J)
2077 NEXT J
2078 LET T6=N(I)-N(I+3)
2079 LET T(39,I)=(T6+T8)*.04+N(I+3)*.005+(O(1)-T8+P(1)+T(26,I))*.1+T(27,I)
2080 LET T(40,I)=T(10,I)/(T(33,I)+T(32,I))
2085 LET T(36,I)=INT(100*T(36,I)+.5)/100
2087 LET T(37,I)=INT(100*T(37,I)+.5)/100
2088 LET T(40,I)=INT(T(40,I)*100+.5)/100
2090 LET T(12,I)=INT(100*T(12,I)+.5)/100
2091 PRINT
2092 LET T(35,I)=INT(100*T(35,I)+.5)/100
2093 LET T(38,I)=INT(100*T(38,I)+.5)/100
2094 LET T(10,I)=INT(T(10,I)+.5)
2095 LET T(39,I)=INT(T(39,I)+.5)
2096 PRINT"CASH AND LIQUIDITY IN " A9+I
2097 PRINT
2098 PRINTTAB(0);"YEAR";TAB(10);"CASH INCREASE";TAB(25);"CASH ACCT";
2099 PRINT TAB(40);"RATIO CASH TO";TAB(55);"RATIO RISK ASSETS"
2100 PRINT TAB(10);"AFTER RES";TAB(25);"END OF YEAR";TAB(40);"DEPOSITS";
2101 PRINT TAB(55);"TO CAPITAL"
2102 FOR J=1 TO I
2103 PRINT TAB(0);A9+J;TAB(10);T(21,J);TAB(25);T(22,J);TAB(40);T(36,J);
2104 PRINT TAB(55);T(37,J)
2105 NEXT J
2106 PRINT
2107 PRINT "DO YOU WANT TO CHANGE PORTFOLIO INVESTMENT DURING" A9+I
2108 PRINT"(YES OR NO)";
2109 INPUT K4$
2110 IF K4$="NO" THEN 2114
2112 GO SUB 6000
2113 GO TO 1590
2114 PRINT
2115 PRINT"YEAR","EARNINGS","LOANS/DEPOSITS","DEPOSITS/CAPITAL"
2120 FOR J=1 TOI
2130 PRINT A9+J,T(10,J),T(35,J),T(38,J)
2140 NEXT J
2145 PRINT
2146 PRINT
2147 PRINT "DO YOU WANT TO CHANGE THE DIVIDEND IN";A9+I;"(YES OR NO)";
2148 INPUT T5$
2149 IF T5$="YES" THEN 1864
2150 PRINT
2151 PRINT "DO YOU WANT TO PROJECT"A9+I+1;"(YES OR NO)";
2160 INPUT L9$
2165 LET M=L1=X1=Y1=A2=J4=A4=A8=D4=D9=0
2166 LET K5=0
2170 IF L9$="NO" THEN 2200
2172 LET L8=L5
2173 LET L5=0
2190 NEXT I
2200 FOR J=1 TO 11
2210 FOR L=1 TO 10
2220 LET T(J,L)=INT(T(J,L)+.5)
2230 NEXT L
2240 NEXT J
2250 FOR J=13 TO 34
2260 FOR L=1 TO 10
2270 LET T(J,L)=INT(T(J,L)+.5)
2280 NEXT L
2290 NEXT J
2400 PRINT"DO YOU WANT TO PRINT STATEMENTS (YES OR NO)";
2410 INPUT O9$
2415 IF O9$="NO" THEN 9999
2420 PRINT
2421 LET J=1
2422 PRINT TAB(25);
2425 IF I>4 THEN 2455
2449 FOR L=1 TO I
2451 PRINT A9+L;TAB(25+12*L);
2453 NEXT L
2454 GO TO 2469
2455 IF I>8 THEN 2462
2456 FOR L=5 TO I
2457 PRINT A9+L;TAB(25+12*(L-4));
2459 NEXT L
2460 GO TO 2469
2462 FOR L=9 TO I
2463 PRINT A9+L;TAB(25+12*(L-8));
2464 NEXT L
2469 PRINT
2470 PRINT"STATEMENT OF EARNINGS"
2475 PRINT"- - - - - - - - - -"
2480 PRINT"INTEREST ON LOANS";
2490 GO SUB 7000
2500 PRINT
2510 PRINT"INTEREST ON INVESTMENTS";
2520 GOSUB 7000
2530 PRINT
2540 PRINT"OTHER INCOME";
2550 GOSUB 7000
2560 PRINT
2570 PRINT"TOTAL INCOME";
2580 GOSUB 7000
2590 PRINT
2600 PRINT
2610 PRINT"INTEREST PAID";
2620 GOSUB 7000
2630 PRINT
2640 PRINT"OTHER OPERATING EXPENSE";
2650 GOSUB 7000
2670 PRINT
2680 PRINT"TOTAL OPERATING EXPENSE";
2685 GO SUB 7000
2690 PRINT
2700 PRINT
2710 PRINT"PRETAX EARNINGS";
2720 GO SUB 7000
2730 PRINT
2740 PRINT"INCOME TAXES";
2750 GO SUB 7000
2760 PRINT
2770 PRINT"NET OPERATING EARNINGS";
2780 GO SUB 7000
2790 PRINT
2800 PRINT"EARNINGS AFTER RESERVES";
2805 GOSUB 7000
2810 PRINT
2820 PRINT
2830 PRINT"EARNINGS PER SHS";
2840 GOSUB 7000
2850 PRINT
2860 PRINT
2870 PRINT"FLOW OF FUNDS STATEMENT"
2880 PRINT"- - - - - - - - - - -"
2890 PRINT"NET OPERATING EARNINGS";
2900 GO SUB 7000
2910 PRINT
2920 PRINT"DEPREC LESS CAPITAL EXP";
2930 GOSUB 7000
2940 PRINT
2950 PRINT"INVESTMENTS";
2960 GO SUB 7000
2970 PRINT
2980 PRINT"LOANS";
2990 GO SUB 7000
3000 PRINT
3010 PRINT"TIME DEPOSITS";
3020 GO SUB 7000
3030 PRINT
3040 PRINT"DEMAND DEPOSITS";
3050 GOSUB 7000
3060 PRINT
3070PRINT"DIVIDENDS";
3080 GOSUB 7000
3090 PRINT
3100 PRINT "TOTAL CHANGE IN CASH";
3110 GOSUB 7000
3120 PRINT
3130 PRINT "CASH AVAILABLE AFTER RES";
3140 GOSUB 7000
3150 PRINT
3160 PRINT
3170 PRINT"STATEMENT OF CONDITION"
3180 PRINT"- - - - - - - - - - - - - - -"
3190 PRINT"CASH";
3200 GOSUB 7000
3210 PRINT
3220 PRINT"GOVERNMENT OBLIGATIONS";
3230 GOSUB 7000
3240 PRINT
3250 PRINT"STATE & POLIT OBLIG";
3260 GOSUB 7000
3270 PRINT
3280 PRINT"OTHER INVESTMENTS";
3290 GOSUB 7000
3300 PRINT 
3310 PRINT"LOANS LESS RESERVE";
3320 GOSUB 7000
3330 PRINT
3340 PRINT "OTHER ASSETS";
3350 GOSUB 7000
3360 PRINT
3370 PRINT "TOTAL ASSETS";
3380 GOSUB 7000
3390 PRINT
3400 PRINT
3410 PRINT"DEMAND DEPOSITS";
3420 GOSUB 7000
3425 PRINT
3430 PRINT"TIME DEPOSITS";
3440 GOSUB 7000
3450 PRINT
3460 PRINT"OTHER LIABILITIES";
3470 GOSUB 7000
3480 PRINT
3490 PRINT"RESERVES";
3500 GOSUB 7000
3510 PRINT
3520 PRINT"CAPITAL";
3530 GOSUB 7000
3540 PRINT
3550 PRINT"TOTAL LIABILITIES";
3560 GOSUB 7000
3570 PRINT
3580 PRINT
3590 PRINT"LOANS/DEPOSITS";
3600 GOSUB 7000
3610 PRINT
3620 PRINT"CASH/DEPOSITS";
3730 GOSUB 7000
3740 PRINT
3750 PRINT"RISK ASSETS/CAPITAL";
3760 GOSUB 7000
3770 PRINT
3780 PRINT"DEPOSITS/CAPITAL";
3790 GOSUB 7000
3791 PRINT
3792 PRINT"FED MINIMUM CAPITAL";
3793 GOSUB 7000
3794 PRINT
3795 PRINT"RETURN ON CAPITAL";
3796 GOSUB 7000
3800 PRINT
3801 IF I<9 THEN 3808
3803 LET I=8
3805 GO TO 3820
3808 IF I<5 THEN 4999
3810 LET I=4
3815 PRINT
3820 PRINT
4010 PRINT"DO YOU WANT TO PRINT STATEMENT FOR THE NEXT FOUR YEARS"
4020 PRINT"(YES OR NO)";
4030 INPUT O9$
4050 IF O9$ ="NO" THEN 4999
4052 GO TO 2421
4999 STOP
5000 FOR I=5 TO 1 STEP-1
5001 REM LEAST SQUARES CALCULATION
5010 READ G(I)
5020 NEXT I
5030 LET R=G(1)
5040 LET T1=5
5050 LET T2=T3 =0
5060 FOR I=1 TO 5
5070 IF G(I)> 0 THEN 5090
5080 PRINT "DO NOT ENTER ZERO IN LINES 1000-1007"
5090 LET T2=T2+LOG(G(I))
5100 LET T3=T3-I*LOG(G(I))
5110 NEXT I
5120 LET B1=(-T1)*(T1+1)/2
5130 LET B2=(-B1)*(2*T1+1)/3
5140 LET B3=T1*T3-B1*T2
5150 LET B5=T1*B2-B1^2
5160 LET B4=B3/B5
5170 LET R1=EXP(B4)-1
5180 RETURN
5200 MATS=ZER(10)
5201 REM PROJECTS FOR 10 YEARS USING TRENDS
5210 FOR I=1 TO 10
5220 LET S(I)=K+S(I-1)+(S(I-1)+K)*Q(I,J)
5225 LET K=0
5230 NEXT I
5240 RETURN
6000 PRINT
6001 REM INVESTMENT SIMULATION
6060 PRINT"ENTER ASSET NO (1=GOVERN'TS,2=MUNICIPALS,3=OTHER,4=LIQ LOANS)";
6070 INPUT K5
6080 ON K5 GO TO 6100,6200,6300,6390
6100 PRINT
6110 PRINT"ARE GOVERNMENTS PURCHASED OR SOLD";
6120 GOSUB 8000
6156 LET N(2)=(N(2)*N(1)+K8*K7)/(N(1)+K7)
6157 LET N(1)=N(1)+K7
6158 LET N(I+J1+2)=N(I+J1+2)+K7
6159 GO TO 6400
6177 LET N(2)=(N(2)*N(1)-(K8*J3))/(N(1)-J3)
6180 LET N(1)=N(1)-J3
6185 LET N(I+J1+2)=N(I+J1+2)-J3
6190 GO SUB 8100
6196 GO TO 6400
6200 PRINT
6210 PRINT "ARE MUNICIPALS PURCHASED OR SOLD";
6220 GOSUB 8000
6257 LET O(2)=(O(2)*O(1)+K8*K7)/(O(1)+K7)
6258 LET O(1)=O(1)+K7
6259 LET O(I+J1+2)=O(I+J1+2)+K7
6260 GO TO 6400
6277 LET O(2)=(O(2)*O(1)-(K8*J3))/(O(1)-J3)
6280 LET O(1)=O(1)-J3
6285 LET O(I+J1+2)=O(I+J1+2)-J3
6290 GO SUB 8100
6296 GO TO 6400
6300 PRINT
6310 PRINT"ARE OTHER INVESTMENTS PURCHASED OR SOLD";
6320 GO SUB 8000
6356 LETP(2)=(P(2)*P(1)+K8*K7)/(P(1)+K7)
6357 LET P(1)=P(1)+K7
6358 LET P(I+J1+2)=P(I+J1+2)+K7
6359 GO TO 6400
6377 LET P(2)=(P(2)*P(1)-(K8*J3))/(P(1)-J3)
6380 LET P(1)=P(1)-J3
6385 LET P(I+J1+2)=P(I+J1+2)-J3
6387 GOSUB 8100
6388 GO TO 6400
6390 GOSUB 8200
6400 PRINT
6405 PRINT"DO YOU WISH TO MAKE MORE PORTFOLIO CHANGES"
6410 PRINT"(YES OR NO)";
6415 INPUT K5$
6420 IF K5$="YES" THEN 6000
6430 GO TO 1500
6990 REM LINES 7000-7080. SPACES AND PRINTS OUT STATEMENT OF
6993 REM EARNINGS, FLOW OF FUNDS STATEMENT, AND STATEMENT OF CONDITION.
7000 PRINT TAB(25);
7025 IF I>4 THEN 7055
7049 FOR L= 1 TO I
7051 PRINT T(J,L);TAB(25+12*L);
7053 NEXT L
7054 GO TO 7070
7055 IF I>8 THEN 7062
7057 FOR L=5 TO I
7058 PRINT T(J,L);TAB (25+12*(L-4));
7059 NEXT L
7060 GO TO 7070
7062 FOR L=9 TO I
7063 PRINT T(J,L);TAB(25+12+(L-8));
7064 NEXT L
7070 LET J=J+1
7080 RETURN
8000 INPUT K6$
8002 IF K6$="SOLD" THEN 8050
8003 PRINT"ENTER AMOUNT,RATE,QUARTER PURCHASED(1-4), YEARS TO MATURITY"
8009 INPUT K7,K8,K9,J1
8010 LET K8=K8/100
8015 LET J4=J4+K7
8020 LET L1=L1+((K9/4)*K7)*(-K8)
8030 RETURN
8050 PRINT"ENTER PROCEEDS,RATE,QUARTER SOLD(1-4),YEARS TO MATURITY,"
8052 PRINT"GAIN OR LOSS (-)";
8054 INPUT J3,K8,K9,J1,J2
8056 LET K8=K8/100
8060 LET L1=L1+((K9/4)*J3)*K8
8070 LET J4=J4-J3
8080 ON K5 GO TO 6177,6277,6377
8100 IF J2>0 THEN 8130
8110 LET Y1=Y1 +J2
8120 RETURN
8130 LET X1=X1+J2
8140 RETURN
8200 PRINT
8210 PRINT"ENTER AMOUNT PURCHASED, RATE";
8220 INPUT K7,K8
8225 LET K8=K8/100
8230 LET L4=L4+K7*K8
8240 LET L5=L5+K7
8250 LET L6=L4/L5
8260 LET L7=L7+K7*K8
8270 RETURN
9999 END