Use more clojure idomatic _last_ function.
Refactor logic into helper methods,
making the code more readable.
Making helpers private