Number Pad Reader
A short description of what the routine does.
{$input}
The variable(s) that the routine stores to at the end.
Ans - Number pressed
TI-83/84/+/SE
{$variable}
{$compatibility}
???
???
URL: UnitedTI brainteaser
:Repeat Ans<=9
:Repeat Ans
:getKey
:End
:Ans(102≠Ans)-13int(Ans/13(2>abs(5-abs(5-abs(Ans-83
:End
The routine waits for a key that corresponds to a number. (0-9)
All magic is on lengthy line.
A nifty optimized routine. Many programs should update to use this one.
Modifications
- You can delete the :Repeat Ans<=9 :End loop to not wait
- Delete the (102≠Ans) if you don't need the 0 number
Error Conditions
None known.
Related Routines
- Keyboard routines
.
