I think regex free solution is best for this

(defn last-indexof [s c]
   (->> s (filter #(= c %)) count dec)


On Nov 12, 3:36 am, "jongwon.choi" <oz.jongwon.c...@gmail.com> wrote:
> Hi
>
> I'm wondering the best way to express:
>
>      (position #\a "abba" :from-end t)
>
> Should I use interop?
>
>      (.lastIndexOf "abba" (int \a))
>
> Thanks!

-- 
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

Reply via email to