Defining cond
cond ? ?b ? ?c ? ?a ? b c a
cond true 2 1(?b ? ?c ? ?a ? b c a) true 2 1
(?c ? ?a ? true c a) 2 1
(?a ? true 2 a) 1
true 2 1
(?t ? ?f ? t) 2 1
(?f ? 2) 1
2
Of course, we could represent 1 and 2 explicitly as functions, too
Previous slide
Next slide
Back to first slide
View graphic version