This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author tim.peters
Recipients tim.peters, vicpires
Date 2018-07-13.17:04:13
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1531501453.89.0.56676864532.issue34109@psf.upfronthosting.co.za>
In-reply-to
Content
?  I expect your code to return -1 about once per 7**4 = 2401 times, which would be about 400 times per million tries, which is what your output shows.

If you start with -5, and randint(1, 7) returns 1 four times in a row, r5 is left at -5 + 4 = -1.
History
Date User Action Args
2018-07-13 17:04:13tim.peterssetrecipients: + tim.peters, vicpires
2018-07-13 17:04:13tim.peterssetmessageid: <1531501453.89.0.56676864532.issue34109@psf.upfronthosting.co.za>
2018-07-13 17:04:13tim.peterslinkissue34109 messages
2018-07-13 17:04:13tim.peterscreate