User input/Text: Difference between revisions
Content added Content deleted
(Fixed to most recent version) |
m (→{{header|REXX}}: added more wording to the REXX section header, added/changed comments and whitespace.) |
||
Line 1,421: | Line 1,421: | ||
=={{header|REXX}}== |
=={{header|REXX}}== |
||
Note: |
Note: all of the following would be accepted as being numerically equal to '''75000''': |
||
:* '''7.5E+0004''' |
|||
⚫ | |||
:* '''75000.''' |
|||
say 'Please enter a string:'; parse pull userString |
|||
:* '''750000e-01''' |
|||
say 'You entered this string:' userString /* show it on the console */ |
|||
;* '''000075000.0000''' |
|||
⚫ | |||
:* ''' 75000 ''' (with leading and/or trailing blanks) |
|||
⚫ | |||
:* and others |
|||
⚫ | |||
⚫ | |||
If the intent was to have the user enter the string exactly as '''75000''', |
|||
⚫ | |||
<br>then the REXX '''do''' statement should be replaced with: |
|||
⚫ | |||
do until userNumber==75000 |
|||
⚫ | |||
⚫ | |||
say 'Please enter a string:' /*issue a prompt message to the term. */ |
|||
parse pull userString /*the (char) string can be any length. */ |
|||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
=={{header|Ring}}== |
=={{header|Ring}}== |