Hacker News new | ask | show | jobs
by Morgawr 4405 days ago
There are a lot of reasons to prefer RPN over infix syntax and why Lisp has chosen to adopt this notation. Although, I agree with the critiques of the article, it's not really saying much.
1 comments

RPN is postfix notation. You add 1 and 2 using "1 2 +"

Lisp is prefix notation, which is just the opposite.

I just realized that makes Lisp "Polish Notation".

I'm sure that opens up some really horrible jokes.

Not quite. If you drop Lisp's variable-arity operators, that enables you to drop the parenthesis. If you drop the parenthesis, that gives you Polish notation.

For example:

  Lisp:  (* (+ 1 2 3) (- 4 5) )

  Polish: * + + 1 2 3 - 4 5
To me, it opened up a really horrible thought: Polish plus Hungarian.

Lisp with Hungarian names (shudder).

You're correct, I brain farted.