title: how many times does a string repeat itself - python?
body: <p>I have strings in python like 'abcabcabc', 'abcdbabcdb'. How do I return the number of times a substring repeats itself within a string?</p>
  
  <p>You want to find the longest substring in a string and return the occurrences. 
  The first one would return 3, and the second one would return 2.</p>