Execute Brain****/TI-83 BASIC: Difference between revisions

m
Categorization now in master page
No edit summary
m (Categorization now in master page)
Line 1:
[[Category:TI-83 BASIC]]{{implementation|Brainf***}}{{collection|RCBF}}
This implementation (in [[TI-83 BASIC]]) is extremely limited by the TI-83 calculator. The closest thing the calculator has to an [[array]] for memory space is a list. Lists in the calculator can't be given a size, they have to be filled in element by element. To expand the space, an element must be added one space after the end and no farther. This program increases the list length as the BF program needs it (dynamically), so it will never run out of space so long as the calculator has the memory to support it. The maximum memory space size is dependent on the amount of memory already taken up by variables and other programs, but is theoretically unlimited. Also, the calculator doesn't use ASCII, so its input and output is a bit different. It takes in a single number (any number of digits, truncates decimal places) for input, and outputs a single number (any number of digits) on each line. If letters are used on input, their variable value is used. For undefined variables, 0 is used. For words typed in without quotes, all of the variables are multiplied and that result is used (if any variable is not defined, 0 is used for that variable). If a word is typed in quotes as input, an error is thrown since it is expecting a number and the program exits. The speed of this program isn't pretty. The code <tt>,[.-]</tt> works as a pretty good seconds countdown. The calculator probably wasn't designed with these kinds of string operations in mind.
 
String variable definitions:
Anonymous user