more Shortest Repetition

Python2