From df18df8868ccecff2f429f08a2510450908dee26 Mon Sep 17 00:00:00 2001 From: Yuichi Nishiwaki Date: Tue, 9 Sep 2014 01:31:25 +0900 Subject: [PATCH] [bugfix] even? and odd? broken --- piclib/scheme/base.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/piclib/scheme/base.scm b/piclib/scheme/base.scm index bddd8bd6..ad8a1679 100644 --- a/piclib/scheme/base.scm +++ b/piclib/scheme/base.scm @@ -191,7 +191,7 @@ (< x 0)) (define (even? x) - (= x (* (/ x 2) 2))) + (= x (* (exact (floor (/ x 2))) 2))) (define (odd? x) (not (even? x)))