Why does Scheme need both "cond-else" and "if" constructs?

chris at seberino.org chris at seberino.org
Fri Jan 25 23:26:19 PST 2008


It seems to me that "cond+else" and "if" do the same thing.
Not sure why Scheme has/needs BOTH.

e.g.

(define (find-sign x) (cond	((< x 0) "negative")
				(else "positive")))

(define (find-sign x) (if	(< x 0) "negative" "positive"))




cs



More information about the KPLUG-LPSG mailing list