Wednesday, May 6, 2009

Boolean assignment

Boolean Searching Strategies


The following candies are records in your database. They have the following properties:

Twix contain chocolate, cookie, and caramel
Caramel Kisses chocolate and caramel
Snickers contain chocolate, caramel, and nuts
Kit Kat contain chocolate and cookie
Caramels contain caramel (!)

What would be the results of the following search statements?


1. Caramel NOT Nuts = Twix, Carmel Kisses, Caramels

2. Chocolate OR Caramel = Twix, Caramel kisses, Snickers, Kit Kat, Caramels

3. (Chocolate AND Caramel) NOT Cookie = Caramel Kisses, Snickers

4. Chocolate OR Nuts = Twix, Caramel kisses, Snickers, Kit Kat,

5. Cookie AND Chocolate = Twix, Kit Kat

6. Chocolate NOT Caramel = Kit Kat

7. Nuts OR Caramel = Caramel Kisses, Snickers, Caramels

No comments:

Post a Comment