I'd like to handle user input in
dc
.
For ?
, info dc
indicates:
'?'
Reads a line from the terminal and executes it. This command
allows a macro to request input from the user.
However, if I type this command sequence to square a number, followed by my input 9
:
?d*p
9
I get:
dc: stack empty
dc: stack empty
dc: stack empty
Am I misinterpreting what ?
does?
Asked by Yimin Rong
(953 rep)
Jul 29, 2017, 12:42 PM
Last activity: Jul 29, 2017, 02:07 PM
Last activity: Jul 29, 2017, 02:07 PM