When I use this code:
(def ISBN-LENGTH 13)
(def OLD-ISBN-LENGTH 10)
(defn valid-isbn [isbn]
(or (= (count isbn) OLD-ISBN-LENGTH)
(= (count isbn) ISBN-LENGTH)))
And then enter: (valid-isbn 05967)
and submit for evaluation, nothing at all happens, no error message.
It has a leading zero so is invalid code but still should present an error message of some sort I would think.
When I use this code: (def ISBN-LENGTH 13) (def OLD-ISBN-LENGTH 10) (defn valid-isbn [isbn] (or (= (count isbn) OLD-ISBN-LENGTH) (= (count isbn) ISBN-LENGTH)))
And then enter: (valid-isbn 05967) and submit for evaluation, nothing at all happens, no error message. It has a leading zero so is invalid code but still should present an error message of some sort I would think.