Reverse Polish notation (RPN) is a mathematical notation wherein every operator follows all of its operands, in contrast to Polish notation, which puts the operator in the prefix position. It is also known as postfix notation and is parenthesis-free as long as operator arities are fixed. The description "Polish" refers to the nationality of logician Jan Łukasiewicz, who invented (prefix) Polish notation in the 1920s.
The reverse Polish scheme was proposed in 1954 by Burks, Warren, and Wright and was independently reinvented by F. L. Bauer and E. W. Dijkstra in the early 1960s to reduce computer memory access and utilize the stack to evaluate expressions. The algorithms and notation for this scheme were extended by Australian philosopher and computer scientist Charles Hamblin in the mid-1950s.
During the 1970s and 1980s, RPN was even known to the general public, as it was widely used in handheld calculators of the time – for example, the HP-10C series and Sinclair Scientific calculators.
In computer science, postfix notation is often used in stack-based and concatenative programming languages. It is also common in dataflow and pipeline-based systems, including Unix pipelines.
Most of what follows is about binary operators. A unary operator for which the reverse Polish notation is the general convention is the factorial.
Read more about Reverse Polish Notation: Explanation, Practical Implications, Converting From Infix Notation
Famous quotes containing the words reverse and/or polish:
“During the late war [the American Revolution] I had an infallible rule for deciding what [Great Britain] would do on every occasion. It was, to consider what they ought to do, and to take the reverse of that as what they would assuredly do, and I can say with truth that I was never deceived.”
—Thomas Jefferson (17431826)
“Use the stones of another hill to polish your own jade.”
—Chinese proverb.