On Friday 25 September 2009 at 08:46 pm, Travis wrote: > > I'm doing some file streaming with a lazy list and I ran into a > problem where I had to process a whole chunk at a time, so I wrote > this function. Just posting to see if I'm reinventing something or if > it might be a good addition to contrib. > > (defn in-smaller-lists [the-list smaller-list-size] ... > > Example: > > user=> (in-smaller-lists (range 11) 3) > ((0 1 2) (3 4 5) (6 7 8) (9 10)) > How about:
user=> (partition 3 3 nil (range 11)) ((0 1 2) (3 4 5) (6 7 8) (9 10)) --~--~---------~--~----~------------~-------~--~----~ 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 Note that posts from new members are moderated - please be patient with your first post. 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 -~----------~----~----~----~------~----~------~--~---