human
Find all occurrences of a substring in Python
assistant
Here is some code to find indexes of all occurrences of a substring `tt` in a string `ttt`

[m.start() for m in re.finditer('(?=tt)', 'ttt')]

#Warning: this code generation is experimental. Please inspect the code for any bugs before executing.