On Tue, Mar 3, 2009 at 2:03 PM, lps540 <lps...@gmail.com> wrote: > > I've written a small example of Conway's Game of Life using Clojure > and Swing. Comments/critiques are welcome. > > http://lpsherrill.blogspot.com/2009/02/conways-game-of-life.html
The paint-cells function can be shorted by using doseq and destructuring. (defn paint-cells [graphics] (doseq [[[x, y] state] @cells] (doto graphics (.setColor (if state Color/RED Color/WHITE)) (.fillRect (* 10 x) (* 10 y) 10 10)))) -- R. Mark Volkmann Object Computing, Inc. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~----------~----~----~----~------~----~------~--~---