-3

Basically I have a while loop that I want to run until either userWins or botWins equal 5. But with this code it will only stop when the variable "userWins" equals 5. I'm newer to python so I don't know if there is a different operator I am supposed to use to make this happen. Thank you for your help.

while userWins < 5 or botWins < 5:

1 Answers1

1

So you want to run while both userWins and botWins are lower than 5. You should use while userWins < 5 and botWins < 5: that's not a programming problem but a logic problem.

Jao
  • 558
  • 2
  • 12
  • Man thank you. I have been working on this program for like 5 hours my brain logically thought it had to be or. I am just losing my mind I guess. – Michael Peterson Sep 22 '20 at 10:23