fix is-pos? and is-neg? functions
This commit is contained in:
@@ -1,8 +1,8 @@
|
|||||||
; not a bool
|
; not a bool
|
||||||
(defn not (x) (if x nil #t))
|
(defn not (x) (if x nil #t))
|
||||||
|
|
||||||
(defn is-pos? (n) (> n nil))
|
(defn is-pos? (n) (> n 0))
|
||||||
(defn is-neg? (n) (< n nil))
|
(defn is-neg? (n) (< n 0))
|
||||||
|
|
||||||
(defn neg (n) (- 0 n))
|
(defn neg (n) (- 0 n))
|
||||||
(defn dec (n) (- n 1))
|
(defn dec (n) (- n 1))
|
||||||
|
|||||||
Reference in New Issue
Block a user