RPN Calculator

Please enter your input:
Result:

Instructions:

This is a Reverse Polish Notation calculator.

Supported syntax:

Most of the operators documented in this RPN CLI tool are available. Variables haven't yet been implemented (should be easy, WIP), and macros will require slight refactoring to implement. The = operator is an alias to pop (the stack is fully visible anyway).

Separators
{ <space> | ; | , }
NB: , may be allowed as a decimal separator in the future, please avoid it!
Equal sign
The equal sign (=) is aliased to pop: 2 3 + = leaves the answer in the result box and an empty stack to start over.
Numbers
Decimal (1.5, 1e3), or hexadecimal, binary and octal integers (0x1f, 0b101, 0o17), optionally signed.
Errors
A line with an error is not applied at all: the stack is left unchanged and the line stays in the input with the faulty part selected, ready to be fixed.
Undo
↶ / ↷, Ctrl+Z / Ctrl+Y or typing undo / redo undo or redo one input line. Undone history is greyed until a new line replaces it. The keys undo the input text first, until it's empty, then the calculator, and redo in reverse order.
Clear
clear (cl) or Clear empties the stack and can be undone. reset (rst) or Reset also erases the history and can't be undone. × or Esc clears the input.

Stack ↑

History ↓

Instructions