"""simple docstring"""



def    _A(		lowerCAmelCase       ):
							if not isinstance(lowerCAmelCase ,     lowerCAmelCase       ):
														raise TypeError("""recursive_lucas_number accepts only integer arguments."""       )
							if n_th_number == 0:
														return 2
							if n_th_number == 1:
														return 1

							return recursive_lucas_number(n_th_number - 1       ) + recursive_lucas_number(
							    n_th_number - 2       )

def    _A(		lowerCAmelCase       ):
							if not isinstance(lowerCAmelCase ,     lowerCAmelCase       ):
														raise TypeError("""dynamic_lucas_number accepts only integer arguments."""       )
							A__							,       A__					:    Optional[Any]														= 2, 1
							for _ in range(lowerCAmelCase       ):
														A__							,       A__					:    Optional[Any]														= b, a + b
							return a


if __name__ == "__main__":
				from doctest import testmod

				testmod()
				_UpperCamelCase         =		int(input("Enter the number of terms in lucas series:\n").strip())
				print("Using recursive function to calculate lucas series:")
				print(" ".join(str(recursive_lucas_number(i)) for i in range(n)))
				print("\nUsing dynamic function to calculate lucas series:")
				print(" ".join(str(dynamic_lucas_number(i)) for i in range(n)))






"""simple docstring"""



def    _A(		lowerCAmelCase       ):
							A__					:    str														= len(lowerCAmelCase       )
							A__					:    List[Any]														= [0] * length
							A__					:    Union[str, Any]														= [[False for i in range(lowerCAmelCase       )] for j in range(lowerCAmelCase       )]
							for i, c in enumerate(lowerCAmelCase       ):
														A__					:    Dict														= i
														for j in range(i + 1       ):
																					if c == string[j] and (i - j < 2 or is_palindromic[j + 1][i - 1]):
																												A__					:    List[str]														= True
																												A__					:    Optional[Any]														= min(lowerCAmelCase ,     0 if j == 0 else (cut[j - 1] + 1)       )
														A__					:    Optional[int]														= mincut
							return cut[length - 1]


if __name__ == "__main__":
				_UpperCamelCase         =		input("Enter the string: ").strip()
				_UpperCamelCase         =		find_minimum_partitions(s)
				print(F'Minimum number of partitions required for the \'{s}\' is {ans}')





