Bank Statement Checker

Developer(s): Jack Armstrong
Date: 1990
Type: Program
Platform(s): TS 2068
Tags: Finance

Adds up the checks on a bank statement. Enter the number of checks, then each amount at the prompt; the amounts are stored in an array, then added up with a running total, and the program prints the total of the checks. The write-up offers it as an example of storing amounts in an array in one loop and adding them in a second.

Jack Armstrong’s program, with revisions by Dick Wagner, the editor. The Plotter says it works on the TS 1000 and the 2068; the listing as printed is for the TS2068 (line 125 prints a row of underscores, which the TS1000 does not have), and the download is the TS2068 version.

Published in The Plotter December 1990 (Bank Statement Checker).

Image Gallery

Source Code

  10 LET CT=0
  20 PRINT : PRINT "HOW MANY CHECKS? ";
  21 REM
  30 INPUT N
  40 PRINT N
  50 DIM A(N)
  55 FOR K=1 TO N
  60 PRINT : PRINT "INPUT AMOUNT OF EACH CHECK"
  70 INPUT A(K)
  80 PRINT A(K)
  90 NEXT K
  95 PRINT
 100 FOR J=1 TO N
 110 LET CT=CT+A(J)
 115 PRINT CT
 120 NEXT J
 125 PRINT "_______"
 130 PRINT CT;" THE TOTAL OF ";N;" CHECKS."
 200 STOP

Note: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.