 (defn apply-to-iterator [iterator movements]
   (for [movement movements]
     (case (nth movement 0)
-      :next (do
-              (.next iterator)
-              (.key iterator))
-      :seek (do
-              (.seek iterator (nth movement 1))
-              (.key iterator)))))
+      :next [(.next iterator) (.key iterator)]
+      :seek [(.seek iterator (nth movement 1)) (.key iterator)])))
 
 (defn apply-to-elems [elems movements]
   (let [elems (atom elems)]

        (set! old-node node)
        (set! old-ix ix)
        (set! old-end? end?)
        (when (false? end?)
          (if (nil? (.-children node))
            (do
              (set! ix (+ ix 1))

      (case (nth movement 0)
        :next (do
                (swap! elems rest)
                [(not (empty? @elems)) (first (first @elems))])
        :seek (do
                (swap! elems (fn [elems] (drop-while #(key-lt (nth % 0) (nth movement 1)) elems)))
                [(and (not (nil? (first @elems))) (key= (nth movement 1) (first (first @elems)))) (first (first @elems))])))))

(defn run-iterator-prop [min-keys key-len actions movements]
  (let [tree (apply-to-tree (tree min-keys key-len) actions)
