Which is the most clojuresque way to compare characters and string? (single char string)

Viewed 13908

I was wondering about which is the best (clojuresque) way to compare a character and a string in Clojure. Obviously something like that returns false:

(= (first "clojure") "c")

because first returns a java.lang.Character and "c" is a single character string. Does exists a construct to compare directly char and string without invoking a cast? I haven't found a way different from this:

(= (str (first "clojure")) "c")

but I'm not satisfied. Any ideas? Bye, Alfredo

8 Answers
Related