title: How to append to a clojure vec until a certain condition pertaining to the accumulated vec is true?
body: <p>For my minimal example, I would like to append maps into a vec until the sum of one of the map fields reached a certain limit.</p>
  
  <p>This is my attempt.   Obviously wrong because <code>items</code> doesn't change inside the while loop.</p>
  
  <pre><code>(let [items []]
      (into items (while (&lt; (reduce + (map :count items)) 100)
                {:something "x"
                 :count     (+ 1 (rand-int 25))})))
  </code></pre>