random.sample
will return list, in your case - list with just one element. You are comparing list
with int
- never True.You want to use
random.randint(1, 99)
- https://docs.python.org/3/library/random...om.randintor
random.choice(range(1, 100))
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs