On Tue, May 24, 2011 at 4:18 AM, Meikel Brandmeyer <m...@kotka.de> wrote: > Hi, > > maybe subseq to the rescue? > > user=> (first (subseq (sorted-set 1 2 3 4 5 6) > 3)) > 4 > > I'm not sure about the perfomance, but I'd think it's fast?
Yes, this is right. Note you can also walk the other direction using rsubseq: (first (rsubseq (sorted-set 1 2 3 4 5 6) < 3)) ;=> 2 --Chouser http://joyofclojure.com/ -- 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