The GetNthDocument method is widely publicized as the way to loop through a collection.
It works - within a loop, you will progress through a collection and successfully process all documents.
However - on a medium to huge collection, processing speed will deteriorate dramatically.
Why? - because position in the collection is re-established on every GetNthDocument by counting upwards from the first document each and every time. Thus, performance deteriorates as the position increases.
What else then? - Use the GetFirstDocument and GetNextDocument methods in all your collection and see your code speed along!
As a guide, one relatively simple agent running against 110,000 documents took 48+ hours using GetNthDocument and less than 1.5 hours when GetFirstDocument and GetNextDocument was used.