Answer to Tuesday's in-class exercise ------------------------------------- ;; likes-same-food?: boa boa -> boolean ;; returns true if both boas like the same food (define (likes-same-food? boa1 boa2) (string=? (boa-food boa1) (boa-food boa2))) - write the signature/purpose for a Java method likesSameFood ans: // does this boa like the same food as the other boa? boolean likesSameFood (Boa other); - write a test method to test likesSameFood ans: // trixie and billy were examples of Boas we defined in class boolean testLikesSameFood(Tester t){ return t.checkExpect (trixie.likesSameFood(new Boa("Joe", 12, "apples")), true) && t.checkExpect (trixie.likesSameFood(billy), false); }