Casio FX-795P Owner's Manual page 84

Hide thumbs Also See for FX-795P:
Table of Contents

Advertisement

154
CHAPTER 7 © Command Reference
mn,
Explanation:
1@
FORI=1
TO
10
20 FOR J=11
TO 2@
30 PRINT
U3%373
]
4@ NEXT
J
50 NEXT
|
60 END
6) Nesting can be performed with up to 4 levels.
attempted, an error occurs.
7-2
Program Commands
Branched line No.
iG)
Line No.
# program area No.
"Number
0 to 9
GOSUB
Function:
Performs a branching to a specified subroutine.
Parameter:
Line No.:
1 to 9999.
Program area No.:
0 to 9.
Explanation:
1) Performs a branching to a subroutine..A return from this subroutine is per-
formed by executing RETURN.
.
2) To make a 'subroutine inside a subroutine is called nesting which can be
performed with up to 8 levels.
3) Return to the statement next to the GOSUB
statement is performed by
RETURN.
5) When the branched line No. does not exist, an error (Error 4) occurs.
*A numeric expression can also be used for a branched line number anda
'pro-
gram area number.
Example:
10° PRINT "MAIN
106%
2@ GOSUB
100
3@
PRINT "MAIN
30"
48
END
100
PRINT
"SUB
100"
11@
GOSUB
200
12@
RETURN
200
PRINT
"SUB 200"
210
RETURN
155

Advertisement

Table of Contents
loading

Table of Contents