String
131. Palindrome Partitioning
Enumerate every way to cut the string so each piece reads as a palindrome. "Enumerate every way" is the tell for backtracking: at each position, try every palindromic prefix as the next piece and…
Loading…
Enumerate every way to cut the string so each piece reads as a palindrome. "Enumerate every way" is the tell for backtracking: at each position, try every palindromic prefix as the next piece and…
Loading…