Get rid of unnecessary variable usage
This commit is contained in:
parent
ffd56ebb70
commit
d2c8270a4f
3
render
3
render
|
@ -38,10 +38,9 @@ def chunk(iterable, chunksize, fillvalue=None):
|
|||
num_chunks = int(math.ceil(len(iterable) / (chunksize * 1.0)))
|
||||
|
||||
for i in xrange(0, num_chunks):
|
||||
missing = (chunksize * (i + 1)) - len(iterable)
|
||||
start = (chunksize * i)
|
||||
|
||||
if missing > 0:
|
||||
if (chunksize * (i + 1)) > len(iterable):
|
||||
end = len(iterable)
|
||||
else:
|
||||
end = (chunksize * (i + 1))
|
||||
|
|
Loading…
Reference in a new issue