On Sat, Sep 3, 2011 at 1:30 PM, Despite <desp...@gmail.com> wrote: > So, you want to make sure each value in the vector is unique? My > first thought was to put them into a set, then see if the set was > equal to the vector, but clojure's equality doesn't allow for that. > And if you put the set back into a vector, you've changed the order.
Just see if the set is the same *size* as the vector. If there were duplicates, it will be smaller instead. -- Protege: What is this seething mass of parentheses?! Master: Your father's Lisp REPL. This is the language of a true hacker. Not as clumsy or random as C++; a language for a more civilized age. -- 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