(defn char-in-range? [minimum maximum testee]
  (let [int-testee (int testee)]
        (and (>= int-testee (int minimum)) (<= int-testee (int maximum)))))

On Apr 25, 12:47 pm, samppi <[email protected]> wrote:
> Let's say I want to test if a Unicode character is within a certain
> range, #x0-#x1F. What can I do?
>
> (defn char-in-range? [minimum maximum testee]
>    ???)
>
> (def x \3)
>
> (char-in-range? \u0000 \u001F x) ; false
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To post to this group, send email to [email protected]
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