#3557
Find Maximum Number of Non Intersecting Substrings
medium · 30.4% accepted · 76 likes · top 8%
hash table · string · dynamic programming · greedy
Description
You are given a string word.
Return the maximum number of non-intersecting substrings of word that are at least four characters long and start and end with the same letter.
Solution