TI-BASIC:Key Code To Letter: Difference between revisions

From Learn @ Cemetech
Jump to navigationJump to search
Initial automated import
 
No edit summary
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{Template:TI-BASIC:Routine
{{Template:TI-BASIC:Routine
|picture=http://tibasicdev.wikidot.com/local--files/template:command/samplescreenshot.gif
|picture=Samplescreenshot.gif
|summary=Outputs a letter corresponding to a keypress.
|summary=Outputs a letter corresponding to a keypress.
|input=''None''
|input=''None''
|output=''Ans'' - the letter as a string
|output=''Ans'' - the letter as a string
|variable=@@
|variable=
|compatibility= TI-83/84/+/SE
|compatibility= TI-83/84/+/SE
|author=@@
|author=
|authors=Weregoose
|authors=Weregoose
|url=http://weregoose.unitedti.org/routines.html Weregoosepage
|url=http://weregoose.unitedti.org/routines.html Weregoosepage

Latest revision as of 21:56, 24 February 2016

Routine Summary

Outputs a letter corresponding to a keypress.

Inputs

None

Outputs

Ans - the letter as a string

Variables Used


Calculator Compatibility

TI-83/84/+/SE Authors

WeregooseURL: Weregoosepage Download

[*https://www.dropbox.com/s/iqpl210jax3bo3n/Routines.8xg?dl=0 Routines.8xg]

:Repeat Ans>34 and min(Ans≠{44,45,105
:getKey
:End
:sub("ABC**DEFGHIJKLMNOPQRSTUVWXYZθ'* :?",Ans-5int(.1Ans+4),1

The Repeat loop makes sure good input is passed. The last line takes from the string the letter according to the keycode.

Error Conditions

None.

Related Routines