translated example7 to clojure