def iterfind(data, string):
 offset = data.find(string, 0)
 while (offset >= 0):
  (yield offset)
  offset = data.find(string, (offset + len(string)))

def iterfind ( data , string ) : offset = data . find ( string , 0 ) while ( offset >= 0 ) : ( yield offset ) offset = data . find ( string , ( offset + len ( string ) ) )
this function is called by the search_process_memory() method of windows .