Explanation:The string "aab" can be partitioned into ["a", "a", "b"] where each substring is a palindrome, or into ["aa", "b"] where each substring is also a palindrome.
Example 2:
Input:s = "a"
Output:[["a"]]
Explanation:The string "a" is already a palindrome, so the only possible partition is ["a"].
Example 3:
Input:s = "efe"
Output:[["e","f","e"],["efe"]]
Explanation:The string "efe" can be partitioned into ["e", "f", "e"] or ["efe"].