In python I need to be able to cycle through a 19 digit number; what is the typical way of doing this? I'm using python 2.7.x; but will use python 3.x if there is a viable solution.
I have a large number; 1000**5
(and even larger 1000**10
) for example; I need to cycle through this number list in a for loop. I am aware of the time it will take; but because I cannot find a way to cycle through such a big number I'm at a loss.
I've tried with xrange
, range
, and itertools.islice
in python 2.7 and receive Overflow
errors.
Thanks