Google
 

Trailing-Edge - PDP-10 Archives - decuslib20-01 - decus/20-0020/reconc.bnk
There are 2 other files named reconc.bnk in the archive. Click here to see a list.
1' NAME--RECONCIL
2'
4' DESCRIPTION
5'     "RECONCIL"IS A PROGRAM THAT RECONCILES A CUSTOMER'S ENDING
6' STATEMENT BALANCE WITH THOSE CHECKS AND DEPOSITS THAT ARE OUT-
7' STANDING.  STARTING WITH THE ENDING BALANCE, THE PROGRAM 
8' SUBTRACTS OUTSTANDING CHECKS AND ADDS OUTSTANDING DEPOSITS TO
9' ARRIVE AT THE BOOK BALANCE AT THE END OF THE PERIOD.  THE ADJUSTED
10' BOOK BALANCE IS THE BOOK BALANCE MINUS SERVICE CHARGES.
11'
12' SOURCE--WRITTEN 10/16/67 BY H.C. SIMPSON, JR.  REVISED 8/8/69
13' BY J. ROKUS
14'
15' INSTRUCTIONS
16'      THE PROGRAM WILL ASK YOU TO INPUT SOME INFORMATION.  FIRST,
17' IT WILL ASK YOU TO "PLEASE ENTER THE NUMBER AND AMOUNT OF
18' EACH CHECK WRITTEN AND ANY CHECKS OUTSTANDING AT THE BEGINNING
19' OF THE PERIOD."  AFTER THE QUESTION MARK, YOU TYPE THE CHECK
20' NUMBER FOLLOWED BY A COMMA, AND THE CHECK AMOUNT.  WHEN YOU HAVE
21' NO MORE INFORMATION TO ENTER, RESPOND TO THE QUESTION MARK 
22' WITH A "0,0."
23'      NEXT, THE PROGRAM WILL ASK YOU TO "PLEASE ENTER THE NUMBER
24' AND AMOUNT OF EACH CHECK WRITTEN AND ANY CHECKS OUTSTANDING AT
25' THE BEGINNING OF THE PERIOD."  AFTER THE QUESTION MARK, YOU TYPE
26' THE DEPOSIT NUMBER, FOLLOWED BY A COMMA, AND THE DEPOSIT
27' AMOUNT.  WHEN YOU HAVE NO MORE INFORMATION TO ENTER, RESPOND
28' TO THE QUESTION MARK WITH A "0,0."
29   
30   
31'      YOU ENTER DATA INTO THE PROGRAM AS FOLLOWS:
32'  (1) TYPE THE NUMBER OF THE LINE INTO WHICH YOU WANT TO PUT DATA.
33'  (2) TYPE THE WORD "DATA."
34'  (3) TYPE THE DATA REMEMBERING TO SEPARATE EACH PIECE OF INFOR
35'      MATION BY A COMMA.
36' THE DATA THAT YOU ENTER INTO THE PROGRAM IS:
37   
38'         LINE NO.               TYPE OF INFORMATION
39'         --------                ------------------
40'            1690     DATA    ENDING BALANCE, SERVICE CHARGES
41'            1691     DATA    CHECK NUMBER, CHECK AMOUNT
42'            ....     DATA    ENTER 0,0 INTO A LINE WHEN YOU HAVE
43'                             NO MORE DATA
44'            ....     DATA    DEPOSIT NUMBER, DEPOSIT AMOUNT
45'            ....     DATA    0,0 TO SIGNAL NO MORE DEPOSITS
46   
47   
48   
49'       IDENTIFICATION OF VARIABLES USED IN THE PROGRAM
50'        ----------------------------------------------
51' Z=ENDING BALANCE ON STATEMENT, S=SERVICE CHARGE
52' B=NUMBER OF DEPOSITS ON STATEMENT
53' X(1) TO X(100)=CHECK NUMBERS ON STATEMENT
54' Z(1) TO Z(100)=CHECK AMOUNTS ON STATEMENT
55' Y(1) TO Y(100)=DEPOSIT NUMBERS ON STATEMENT
56' R(1) TO R(100)=DEPOSIT AMOUNTS ON STATEMENT
57' C( )=CHECK NUMBERS USED BY CUSTOMER
58' A( )=CHECK AMOUNTS WRITTEN BY CUSTOMER
59' O( ) AND L( )=OUTSTANDING CHECK NUMBERS AND AMOUNTS
60' D( )=DEPOSIT NUMBERS USED BY CUSTOMER
61' F( )=DEPOSITS MADE BY CUSTOMER
62' E( ) AND G( )=OUTSTANDING DEPOSIT NUMBERS AND AMOUNTS
63   
64   
70' THIS PROGRAM WAS WRITTEN FOR STUDENT USE AT AMOS TUCK SCHOOL
71' OF HANOVER, N.H. WHICH DOES NOT ASSUME RESPONSIBILITY FOR
72' ITS ACCURACY.
80'
90' * * * * * * * * * * * * MAIN PROGRAM * * * * * * * * * * * * 
100'
105 DEF FNP(N9) 'THIS FUNCTION PRINTS IN DOLLARS AND CENTS FORMAT
110' N9 IS THE AMOUNT THAT THE FUNCTION PRINTS OUT
122 LET U9=0
124 LET C2=1
130 IF N9=0 THEN 470
140 LET P9=0
150 LET C9=INT(N9*100+.5)
160 LET F9=INT(C9/100)
170 LET R9=C9-100*F9
180 LET T9=INT(F9/10)
190 LET P9=P9+1
200 LET T9=INT(F9/10)
210 LET O(P9)=F9-10*T9+48
220 LET F9=T9
230 IF F9>0 THEN 190
240 LET O(0)=P9+3
250 LETO(P9+1)=46
260 LET O(P9+2)=INT(R9/10)
270 LET O(P9+3)=R9-O(P9+2)*10+48
280 FOR I9=1 TO P9/2
290 LET T9=O(I9)
300 LET O(I9)=O(P9+1-I9)
310 LET O(P9+1-I9)=T9
320 NEXT I9
330 LET O(P9+2)=O(P9+2)+48
340 LET U9=U9+1
350 IF U9=O(0) THEN 420
360 IF O(U9)<>46 THEN 340
370 FOR V9=1 TO 7-U9
380 LET P(V9)=32
390 NEXT V9
400 LET P(0)=V9
410 CHANGE P TO N$
420 CHANGE O TO Q$
430 PRINT N$;Q$;
440 LET FNP=C9/100
450 GO TO 470
460 PRINT"   0";
470 FNEND
480 MATO=ZER(100)
490 DIM L(100),Q(100)
500 LET L8=N=L9=R=0
510 REM READ IN STATEMENT INFORMATION
520 DIM X(100),Y(100),C(100),O(100),D(100),E(100),A(100),Z(100)
530 DIM R(100),F(100),G(100)
535' Z IS ENDING BALANCE
536' S IS SERVICE CHARGES
540 READ Z,S
545' LOOP TO READ CHECK NOS. AND AMOUNT
546' X( ) IS CHECK NOS. ON THE STATEMENT
547' Z( ) IS CHECK AMOUNTS ON THE STATEMENT
550 FOR I=1 TO 100
560 READ X(I),Z(I)
565' WHEN X( )=0, NO MORE CHECKS
570 IF X(I)=0 THEN 600
575' A=TOTAL NO. OF CHECKS ON THE STATEMENT
580 LET A=A+1
590 NEXT I
595' LOOP TO READ DEPOSIT NOS. AND AMOUNT
600 FOR I=1 TO 100
605' Y( ) IS DEPOSIT NOS. ON THE STATEMENT
606' R( ) IS DEPOSIT AMOUNTS ON THE STATEMENT
610 READ Y(I),R(I)
615' WHEN Y( )=0, NO MORE DEPOSITS
620 IF Y(I)=0 THEN 660
625' B=TOTAL NO. OF DEPOSITS ON THE STATEMENT
630 LET B=B+1
640 NEXT I
650 PRINT
660PRINT TAB(12);"RECONCILEMENT OF BANK ACCOUNT"
670PRINT
680 PRINT
685' INPUT LOOP FOR CHECKS WRITTEN AND OUTSTANDING
690 PRINT"PLEASE ENTER THE NUMBER AND AMOUNT OF EACH CHECK WRITTEN AND"
700 PRINT"ANY CHECKS OUTSTANDING AT THE BEGINNING OF THE PERIOD"
710PRINT"(ENTER 0,0 WHEN COMPLETED)"
720PRINT "ENTER NUMBER, AMOUNT"
730 FOR I=1 TO 100
735' C( ) IS CHEK NOS. USED BY CUSTOMER
736' A( ) IS CHECK AMOUNTS WRITTEN BY CUSTOMER
740 INPUT C(I),A(I)
750 IF C(I)=0 THEN 790
755' L8=TOTAL NO. OF CHECKS USED BY CUSTOMER
760LET L8=L8+1
770 NEXT I
780 LET N=0
790 FOR J=1 TO L8
800 FOR I=1 TO A
805' CHECK TO SEE IF THOSE CHECKS WHICH HAVE BEEN WRITTEN ARE ON
806' THE STATEMENT
810 IF C(J)=X(I) THEN 870
820 NEXT I
825' N=TOTAL NO. OF CHECKS OUTSTANDING
827' Q( )=OUTSTANDING CHECK NOS.
828' L( )=OUTSTANDING CHECK AMOUNTS
830 LET N=N+1
840 LET Q(N)=C(J)
850 LET L(N)=A(J)
860 GO TO900
865' FOR THOSE CHECKS USED BY CUSTOMERS AND ON THE STATEMENT, CHECK
866' TO SEE IF AMOUNTS CORRESPOND
870 IF A(J)=Z(J) THEN 890
880PRINT"CHECK NUMBER";C(J);"MAY BE POSTED INCORRECTLY"
890LETX(I)=0
900NEXTJ
905' COMPUTATION OF S3 WHERE S3=TOTAL AMOUNT OF OUTSTANDING CHECKS
910 FORI=1TON
920 LET S3=S3+L(I)
930 NEXTI
940 PRINT
950 PRINT
955' INPUT LOOP FOR DEPOSITS MADE AND OUTSTANDING
960PRINT"PLEASE ENTER THE NUMBER AND AMOUNT OF EACH DEPOSIT MADE AND"
970PRINT"ANY OUTSTANDING AT BEGINNING OF PERIOD"
980PRINT"(ENTER 0,0 WHEN COMPLETED)"
990 PRINT "ENTER NUMBER, AMOUNT"
1000 FOR I=1 TO 100
1005' D( ) IS DEPOSIT NOS. USED BY CUSTOMER
1007' F( ) IS DEPOSIT AMOUNTS MADE BY CUSTOMER
1010 INPUT D(I),F(I)
1020 IF D(I)=0 THEN 1050
1025' L9=TOTAL NO. OF DEPOSITS MADE AND OUTSTANDING
1030 LET L9=L9+1
1040 NEXT I
1050 FOR J=1 TO L9
1060FORI=1TOB
1065' CHECK TO SEE IF THOSE DEPOSITS WHICH HAVE BEEN MADE ARE ON
1066' THE STATEMENT
1070 IF D(J)=Y(I) THEN 1130
1080 NEXTI
1085' R=TOTAL NO. OF DEPOSITS OUTSTANDING
1090 LET R=R+1
1095' E( ) IS DEPOSIT NO. OUTSTANDING
1096' G( ) IS DEPOSIT AMOUNTS OUTSTANDING
1100LETE(R)=D(J)
1110 LET G(R)=F(J)
1120 GO TO1160
1125' FOR THOSE DEPOSITS MADE A