Texas Instruments TI-83 Calculator User Manual


 
16-22 Programming
8316PROG.DOC TI-83 international English Bob Fedorisko Revised: 02/19/01 1:23 PM Printed: 02/19/01 1:39
PM Page 22 of 22
On the TI
-
83, any stored program can be called from
another program as a subroutine. Enter the name of the
program to use as a subroutine on a line by itself.
You can enter a program name on a command line in either
of two ways.
Press
|
to display the
PRGM EXEC
menu and
select the name of the program (page 16
.
7). prgm
name
is
pasted to the current cursor location on a command line.
Select
prgm from the
PRGM CTL
menu, and then enter
the program name (page 16
.
15).
prgm
name
When
prgm
name
is encountered during execution, the next
command that the program executes is the first command
in the second program. It returns to the subsequent
command in the first program when it encounters either
Return or the implied Return at the end of the second
program.
Program Output
&
Subroutine
(
'
Variables are global.
label
used with
Goto and Lbl is local to the program where
it is located.
label
in one program is not recognized by
another program. You cannot use
Goto to branch to a
label
in another program.
Return exits a subroutine and returns to the calling
program, even if it is encountered within nested loops.
Calling Other Programs as Subroutines
Calling a
Program from
Another Program
Notes about
Calling Programs