> On Dec 4, 2016, at 2:18 PM, bill nom nom <[email protected]> wrote: > > ;; This works, > (hash-map :a 1 :b 2 ) > > ;; Here's another way to create a hash map, this won't work because map > ;; literal must contain even number of forms > {hash-map :c "Turd" :d "More Turd"} > > What does "Map literal must contain an even number of forms" mean? That’s not how you use a map literal. That’s trying to create a map of hash-map to :c, “Turd” to :d, and “More turd” to…. nothing — which is why it breaks. You need an even number of forms because you need a value associated with every key. I don’t know where you got that comment about another way to create a hash map, but it is incorrect.
lvh > > -- > You received this message because you are subscribed to the Google > Groups "Clojure" group. > To post to this group, send email to [email protected] > Note that posts from new members are moderated - please be patient with your > first post. > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/clojure?hl=en > <http://groups.google.com/group/clojure?hl=en> > --- > You received this message because you are subscribed to the Google Groups > "Clojure" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected] > <mailto:[email protected]>. > For more options, visit https://groups.google.com/d/optout > <https://groups.google.com/d/optout>. -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to [email protected] Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
