4 ms·
I would imagine debugging is less fun than typing the programs in 20^3 command tree.
by mycall 6y ago
I would imagine debugging is less fun than typing the programs in 20^3 command tree.
- avhon1 6y agoDebugging wasn't too bad. The constraints I remember running into all the time are: * The editor is on a 16-column 8-row display, but the leftmost column always starts with the a ":" and the top row always has the name of the program, so it's more like a 15x7 display. * There are only 27 numeric variables (A-Z and Theta), and X and Y get manipulated whenever you do plotting commands, but you can use the "Answer" variable to pass arguments and results to and from program calls. * There are only 10 string variables, but they are not limited in length (except by total available memory), and you can use eval() on substrings (commence evil laughter!). * Lists have a maximum length (I think 999 items?), but because numbers take up a variable amount of memory, you might run out of memory before the list is full. Or not, it depends! * Same deal with matricies. Finite size (maybe 99x99?), and stored sparse in memory. The number of cells you can write to depends on what numbers you're writing. * All variables are global. (Recursive programs require you to manually save and restore state.) * TI-Basic's interpreter is REALLY slow. Not just because it's a Z80 running at 8 or 12 MHz, it really is inefficient. I learned good tricks (memoization) and terrible ones (omit trailing parentheses, commas, and double-quotes) to make programs faster. * Comments make your code slower (and change the content of the "Answer" variable). Between all of those, I spent way more time writing (and running) programs than debugging them. Fun times!