How to Create a Menu on the TI-84 Plus
The Menu command on the TI-84 Plus graphing calculator is a glorified Goto command. It allows the program user to select an item from a menu, and then have the program execute the commands that are specific to that item.
After executing the commands that are specific to the chosen item, the program can terminate, return to the menu so the user can make another selection, or it can continue by executing the commands in the program that appear after the commands that are specific to the chosen menu item.
The first two pictures illustrate the structure of a menu-driven program that terminates after executing the commands associated with the chosen menu item. If, for example, the user of this theoretical program selects itemA from the menu, commands 1 are executed, and then the Stop command terminates the program.
If the user selects QUIT from the menu, the program clears the Home screen and then terminates because it has no more commands to execute.
The third picture illustrates the menu that the user of the program sees. The moving broken line in the upper-right corner is the calculator’s way of telling the user that it is waiting for a menu item to be selected.
When you create a menu-driven program, it’s a common courtesy to offer QUIT as a menu item. This allows the user to quickly exit the program if he or she inadvertently selects the wrong program to execute.
The first two pictures illustrate the structure of a menu-driven program that returns the user to the menu after they have selected and executed a menu item. If, for example, the user of this program selects THIS from the menu, the calculator executes the commands housed in the external program named THIS, and then returns the user to the menu to make another selection.
The external program named THIS is pictured, in its entirety, in the third picture. If the user selects QUIT from the menu, the program will clear the Home screen and terminate because there are no more commands in the program for it to execute.
When you create a menu-driven program that repeatedly returns the program user to the menu, it’s wise to supply the program with a means of terminating itself. Adding a QUIT option to the menu is an easy way to do so.