I don't doubt that this works (I've seen the results), but this is not the way of looping in Python. One of the goog things of Python is the possibility to use loops like:

```python
for item in iterable:
    #do something with the items
#Or

for i in range(len(object)):
    #If you __really__ need the indexes
```

Manually creating and updating indexes like it is done here is very error prone an unnecessary.

Could you please take a look at that?