postfix.txt

Are you completely tired of parentheses? unfix™ can help!

Observe the following Clojure code:

(- (+ 5 (* 4 (+ 1 2))) 3)
;=> 14

That sure is a lot of parentheses for such a simple formula. Thankfully, using unfix™’s patented infix® technology, we can clean it up a bit:

(infix 
  5 + [[1 + 2] * 4] - 3)
;=> 14

However, there are still parenthesis-like things used that are quite disorienting. unfix™ to the rescue again:

(postfix
  5 1 2 + 4 * + 3 -)
;=> [14]

Amazingly, every single parentheses and parenthesis-like things have disappeared in a puff of Charles Leonard Hamblin’s pipe smoke! Using unfix™’s patented1 postfix®, technology you can drastically reduce your reliance on parentheses and parenthesis-like things:

(postfix "There" ", " "all " "unbetter" str str str)
;=> ["There, all unbetter"]

back to docs…

  1. Patent pending