Predicates
A function that produces a boolean (true or false) value
String Predicates
Non-numeric types also have predicates.
For example, we can tell if two strings are the same:
(string=? “pearls” “gems”) ⇒ false
(string=? “pearls” “pearls”) ⇒ true
we can also compare the lexicographical order or two strings
(string<? “pearls” “swine”) ⇒ true
(string<? “pearls” “pasta”) ⇒ false
(string≤? “pearls” “pearls”) ⇒ true
Conditional Expressions
Sometimes expression can take more than one value
Conditional expressions use the special form cond.
Each argument is a question/answer pair
The question is a boolean expression
The answer is a possible value of the conditional expression
