code: def iter(self, string):
  		
  		state = self.root
  		for index, c in enumerate(string):
  			while c not in state.children:
  				state = state.fail
  
  			state = state.children.get(c, self.root)
  
  			tmp = state
  			output = []
  			while tmp is not nil:
  				if tmp.output is not nil:
  					output.append(tmp.output)
  
  				tmp = tmp.fail
  
  			if output:
  				yield (index, output)
docs: Generator performs Aho-Corasick search string algorithm, yielding
  		tuples containing two values:
  		- position in string
  		- outputs associated with matched strings