Here's one way to do adjacent repeats. https://play.golang.org/p/402UEPtIkfw
But if you don't understand regular expressions, this could be done more simply by: - finding the first occurrence of substr - advancing the offset to just after the end of the match - check if substr appears at the new position - keep repeating until substr cannot be found any more -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/9f51a985-40be-40f1-9259-b4a53d54d6e3o%40googlegroups.com.
