Can anyone explain this? user> (def x {:foo :bar :foo :baz :foo :quux}) #'user/x user> x {:foo :bar, :foo :baz, :foo :quux} user> (count (keys x)) 3 user> (map x (keys x)) (:bar :bar :bar)
It's understandable that a literal map which includes the same key twice with different values could return any one of the given values. But I would expect the resulting map to have one key and one of the values. Note: user> (assoc {} :foo :bar :foo :baz :foo :quux) {:foo :quux} user> (conj {} [:foo :bar] [:foo :baz] [:foo :quux]) {:foo :quux} user> (hash-map :foo :bar :foo :baz :foo :quux) {:foo :quux} --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---