Hello! On 29 Jan., 20:14, Meikel Brandmeyer <m...@kotka.de> wrote: > CL find as I understand it: (some (partial = x) some-coll). Sufficiently ugly > to show performance characteristics. > CL member as I understand it: (drop-while (partial not= x) some-coll). > Sufficiently ugly to show performance characteristics.
Yes, that's basically it. A minor difference: CL:FIND returns the first matching element, so it's more like (first (drop-while (partial not= x) some-col))), but that doesn't really matter, because there are fundamental differences in design anyway. Things like: (find 1337 list :key #'cadr :test #'id) would be done differently in clojure, and also in CL one should probably structure ones code differently, but in the heat of the battle there are sometimes situations where this stuff might be handy (at least in my case). The problem was not the implementation, but I didn't understynd why something akin to member/find is not part of the core language. "Sufficiently ugly" surely is well put; having read the post linked above made me understand the reasoning behind it. Regards dhl -- 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