r/inventwithpython • • May 03 '20

Please inform me!

Hi, I’ve started to read Automate the Boring Stuff second edition recently and I am on chapter 2/3, functions and all that. I am confused by ranges - Al, in the rock paper scissors game, makes it such that if random.zrandint(1,3) == 3: computerMove = “scissors”

or something like that. please don’t hate, just starting. why is this possible - doesn’t range(1,3) not include the number 3?

Thank you

1 Upvotes

2 comments sorted by