Keyboard input/Obtain a Y or N response: Difference between revisions

(ZX Spectrum Basic)
 
(→‎{{header|PureBasic}}: Added PureBasic)
Line 14:
 
[[Category:Keyboard Input]]
=={{header|PureBasic}}==
<lang PureBasic>PrintN("Press Y or N to continue")
Repeat: Key$=UCase(Inkey())
Until Key$="Y" Or Key$="N"
PrintN("The response was "+Key$)</lang>
Anonymous user