def printiter(self, it, output=None):
	if output is None:
	    output = self.output
	self.moreiterator = it
	i = 0
	lastindex = None
	while i < self.maxpaths:
	    try:
		el = it.next()
	    except StopIteration:
		it.reset(0)
		break
	    el.pp(output=output)
	    i += 1
	    lastindex = el.index
	else:
	    if lastindex is not None:
		nummore = (lastindex+1)-self.numpaths
		if nummore == 1:
		    it.next().pp(output=output)
		elif nummore > 1:
		    print >>output, '<... %d more paths ...>'%nummore
dataset/ETHPy150Open cloudera/hue/desktop/core/ext-py/guppy-0.1.10/guppy/heapy/Path.py/ShortestPaths.printiter/swapped operands of `-`