You should be able to use (apply max-key f someseq); apply takes a variable
number of args, and only the last is expanded.
Thanks, thought there would be something like this!
--
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group,
Hi,
I think a better usage for max-key would be
(max-key f someseq)
rather than passing the values as args.
I used
(defn max-key-seq [f someseq]
(apply max-key (into [f] someseq)))
to make it do what I wanted
Is there a better way?
Cheers,
Tom
--
You received this message because you are
On 15 November 2010 14:17, Tom Hall thattommyh...@gmail.com wrote:
Hi,
I think a better usage for max-key would be
(max-key f someseq)
rather than passing the values as args.
I used
(defn max-key-seq [f someseq]
(apply max-key (into [f] someseq)))
to make it do what I wanted
Is there