title: Clojure - sum up a bunch of numbers
body: <p>Hey I'm doing a Project Euler question, and I'm looking to sum up all the numbers under 1000 that are multiplies of 3 or 5. </p>
  
  <p>But being a clojure noob, my code just keeps returning zero.. and I'm not sure why.</p>
  
  <pre><code>(defn sum-of-multiples [max]
    (let [result (atom 0)]
      (for [i (range max)] 
        (if (or (= (rem i 3) 0) (= (rem i 5) 0))
          (swap! result (+ @result i)))    
        )
      @result))
  
  (sum-of-multiples 1000)
  </code></pre>
  
  <p>Also the line <code>(swap! result (+ @result i)))</code> bugs me.. In C# I could do <code>result += i</code>, but  I'm guessing there must be a better way to this in Clojure?</p>