diff --git a/shared/clj/src/core.clj b/shared/clj/src/core.clj index 3711cd1..2d29cac 100644 --- a/shared/clj/src/core.clj +++ b/shared/clj/src/core.clj @@ -142,6 +142,12 @@ ;; conversions +(defn binary->long [binary-str] + (Long/parseLong binary-str 2)) + +(defn long->binary [value] + (Long/toString value 2)) + (def arrow-char->dir {\> :right \v :down \< :left