how to refer to partial list, slice is too slow?

人言落日是天涯,望极天涯不见家 kelvin.you at gmail.com
Fri May 11 01:56:11 EDT 2007


I make a sample here for the more clearly explanation

s = " ..... - this is a large string data - ......."

def parser1(data)
     # do some parser
     ...
     # pass the remainder to next parser
     parser2(data[100:])

def parser2(data)
     # do some parser
     ...
     # pass the remainder to next parser
     parser3(data[100:])

def parser3(data)
     # do some parser
     ...
     # pass the remainder to next parser
     parser4(data[100:])

...





More information about the Python-list mailing list