So for returns a lazy-seq of the combinations and I am forcing it to process the values by filtering. mmm... I still tried your approach and nothing changed in processing time. I changed the for form to filter as it is pairing the combinations, I didn't think it would make any difference since I just moved the filtering to another position, but I still tried:
(defn all-pals [in] (let [len (count in)] (for [i (range 0 (dec (dec len))), j (range (inc i) len) :when (palindrome? (subs in i j))] (do (subs in i j))))) it didn't work with the long input. So how can I filter without processing the values, quite a contradiction. -- 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