I am completely new to programming. I have the book Learn To Program With Minecraft: Transform Your World With The Power Of Python. There is no real customer support for the book.
I'm learning about Logical Operator Order. The book presents the following code as an example:
wolves = input("Enter the number of wolves: ")
enoughWolves = wolves > 10 and wolves < 20
print("Enough wolves: " + str(enoughWolves))
I wrote the code exactly as the book said, but I got the following error:
Traceback (most recent call last):
File "/Users/myName/Documents/wolves.py", line 3, in <module>
enoughWolves = wolves < 20
TypeError: '<' not supported between instances of 'str' and 'int'
I don't understand what this error message means, and I don't understand why the book's code doesn't work. Can anyone help me?