Download Print this page

Casio FP-200 Instruction Manual page 80

Handy personal computer
Hide thumbs Also See for FP-200:

Advertisement

r C R O S S - T O T A L I N G - - - - - - - - - - - - - - - - - - - - - - - - -
This program uses the CETL file FO. Therefore, if this file is already occupied by some
other data, it should be cleared by the K command before the program can be stored.
Note also that inputting extremely large numbers (i.e., so large that a calculation result
exceeds 8 digits} produces incorrect output.
10 'CROSS TOTALING
20 'CROSS TOTAL
20.12
Bytes
30 CLS: CLEAR: F'RINT"CROSS TOTAL ING": PRINT"Ver·t
i ca
1
colunms 24,hor·izontal r·ows 24":F'RINT" rn<":PRINT
40 INF'UT"Number of Colunms.X";X
50 IF X)25 OR X<2 THEN 40
60 INF'UT"Number of rows.
Y";Y
70 IF
Y>25 OR Y<2
THEN 60
80 PRINT:PRINT" X - Y"
90 FOR J=1 TO Y+1:FL<0,X+1,J)=0:NEXT
100 FOR I=l TO X+1:FL(0,I,Y+1)=0:NEXT
110 FOR
J=1
TOY
120 FOR I=l TO
X
130 PR I NT I ; " - " ; J ; " " ; : INPUT
A
140 FL(0,I,J)=A:FL(0,X+1,J)=FL(0,X+1,J)+A:FL(0,I,
Y+l)=FL(0,I,Y+l)+A:NEXT
I
150 PRINT"Sub-total of(Y=";J;">";FL<CZJ,X+l,J):F'RIN
T
160
FL(0,X+1,Y+1)=FL(0,X+1,Y+1)+Fl(0,X+1,J):NEXT
J
170 PRINT"Input completed"
180 PRINT:tNPUT"Do you want to change any itum-::-
X=";Q:IF D<0 OR Q)X THEN 180
190 INF'UT"Y==";W: IF W<IZl
OR
W>Y THEN 190
200 IF Q=0 OR W=0 THEN 280
2 1
QJ
PR I
NTQ; " - " ;
W; "==" ;
FL
(0 ,
Q ,
W)
220 F'RINT"Do you wish to change numeric data')(Y/N
)
"
230 Z$=INKEY$: IF 2$='"' THEN 230 ELSE IF Z$="Y" OR
Z$="y" ~HEN 24(2) ELSE 180
240 F'RINTQ; "-"; W;" ";: INPUT A
250 FL(0,Q,Y+l)=FL(0,Q,Y+1)-FL(0,Q,W)+A:FL<0,X+1,
W>=Fl(0,X+1,W)-FL(0,Q,W)+A
260 FL(0
1
X+1,Y+l)=FL(X0,+1,Y+1)-FL((2),0,W)+A:FL<0,
Q,W>=A
270
F'RINT"Sub-total of
<Y=";W;")";FL<0,X+l,W):GOT
0
180

Advertisement

loading