One things that always bugged me about clojure is that most functions that work on collections return seqs and not the original data structure type:
(= [2 4 6] (-> [2 [4]] flatten (conj 6))) => false Every time I transform collections I need to be aware of this. My questions is: is there a philosophical reason for that or it was implement this way because it's easier? Why conj is different? Doesn't it break the principle of least surprise? Thanks, Islon -- -- 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/groups/opt_out.
