Programming Assignment #7: Guess My Animal

Write a program that plays the "Guess My Animal" game. In the "Guess My Animal" game, one person thinks of an animal, and the other person tries to figure out what animal the other person is thinking of by asking yes/no questions.

Your program should store its knowledge in a file so that it gets better at the "Guess My Animal" game as it plays more and more times. Here is an example run:

> animal
"Guess My Animal" game by Seth Li.

Please think of an animal.  Press return when you are ready:

Is your animal a cat?  no 

I'm sorry, I don't know your animal.  You win.
What animal were you thinking of?  dolphin

Please enter a yes/no question which is true of a cat but not true of
a dolphin:  Does it purr?

Thank you!
>
> animal
"Guess My Animal" game by Seth Li.

Please think of an animal.  Press return when you are ready:

Does it purr? no  
Is it a dolphin?  no

I'm sorry, I don't know your animal.  You win.
What animal were you thinking of?  elephant

Please enter a yes/no question which is true of a dolphin but not ture
of a elephant:  Does it swim?

Thank you!
>
> animal
"Guess My Animal" game by Seth Li.

Please think of an animal.  Press return when you are ready:

Does it purr? no
Does it swim? yes
Is it a dolphin? yes

I WIN!!!!

>