Rewrite comparison script in clojure from ruby