Palindrome partition cuts
Your task
Given a string s, partition it into contiguous substrings such that every part is a palindrome, and return the MINIMUM number of cuts needed. A single character is a palindrome; a string already palindromic needs 0 cuts. 1 <= len(s) <= 2000, lowercase letters. Example: 'aab' -> 1 (cut into 'aa' | 'b').
Examples
min_palindrome_cuts(s: str) -> intExample 1
Input
min_palindrome_cuts("aab")Output
1