If you're gonna go point free...

((comp (partial into {})
           (partial filter (comp even? val)))
  {:dog 5 :cat 4 :mouse 7 :cow 6})

On Sep 2, 11:03 am, Krukow <[email protected]> wrote:
> On Sep 2, 5:02 pm, Krukow <[email protected]> wrote:
>
> > Or if you like "point-free" style
> > (into {}
> >    (filter (comp even? second)
> >             {:dog 5 :cat 4 :mouse 7 :cow 6}))
> > =>
> > {:cat 4, :cow 6}
>
> Saving a few chars, and perhaps more readable:
>
> user> (into {}
>             (filter (comp even? val)
>                     {:dog 5 :cat 4 :mouse 7 :cow 6}))
> {:cat 4, :cow 6}
> user>
>
> /K
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to