On Thursday, May 12, 2016 at 4:10:39 AM UTC-4, Michael Gardner wrote:
>
> There's no need to avoid `apply` altogether, IMO. You could do something 
> like this: 
>
> (let [raw (list :a 1 :b 2 :c 3)] 
>     (into {:raw raw} 
>         (filter (comp even? second) 
>             (apply hash-map raw)))) 
>

Ah, that comp is nice. I'll use that.
 

>
> BTW, `list` is pretty uncommon. Usually you'd just use a vector literal. 
>

Understood, but I am actually working on a function where the values 
originate as a & rest param. 

Hmm, given the oddness of lists in Clojure, I wonder why those aren't 
vectors.

Thx! -kt

-- 
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
--- 
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 clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to