After running 2to3

This commit is contained in:
Grant Sanderson
2018-08-09 17:56:05 -07:00
parent 06a65190e7
commit 858051a806
172 changed files with 2117 additions and 2221 deletions

View File

@ -12,8 +12,8 @@ def choose(n, r):
return 0
if r == 0:
return 1
denom = reduce(op.mul, xrange(1, r + 1), 1)
numer = reduce(op.mul, xrange(n, n - r, -1), 1)
denom = reduce(op.mul, range(1, r + 1), 1)
numer = reduce(op.mul, range(n, n - r, -1), 1)
return numer // denom
# Just to have a less heavyweight name for this extremely common operation