






"""simple docstring"""



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


if __name__ == "__main__":
						__A		:	Tuple      =		input('''Enter the string: ''').strip()
						__A		:	List[str]      =		find_minimum_partitions(s)
						print(F"""Minimum number of partitions required for the '{s}' is {ans}""")











"""simple docstring"""



from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_tokenizers_available, is_torch_available


__A		:	Any      =		{
    '''configuration_realm''': ['''REALM_PRETRAINED_CONFIG_ARCHIVE_MAP''', '''RealmConfig'''],
    '''tokenization_realm''': ['''RealmTokenizer'''],
}

try:
						if not is_tokenizers_available():
												raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
						pass
else:
						__A		:	Tuple      =		['''RealmTokenizerFast''']

try:
						if not is_torch_available():
												raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
						pass
else:
						__A		:	Optional[int]      =		[
						    '''REALM_PRETRAINED_MODEL_ARCHIVE_LIST''',
						    '''RealmEmbedder''',
						    '''RealmForOpenQA''',
						    '''RealmKnowledgeAugEncoder''',
						    '''RealmPreTrainedModel''',
						    '''RealmReader''',
						    '''RealmScorer''',
						    '''load_tf_weights_in_realm''',
						]
						__A		:	Union[str, Any]      =		['''RealmRetriever''']


if TYPE_CHECKING:
						from .configuration_realm import REALM_PRETRAINED_CONFIG_ARCHIVE_MAP, RealmConfig
						from .tokenization_realm import RealmTokenizer

						try:
												if not is_tokenizers_available():
																		raise OptionalDependencyNotAvailable()
						except OptionalDependencyNotAvailable:
												pass
						else:
												from .tokenization_realm import RealmTokenizerFast

						try:
												if not is_torch_available():
																		raise OptionalDependencyNotAvailable()
						except OptionalDependencyNotAvailable:
												pass
						else:
												from .modeling_realm import (
												    REALM_PRETRAINED_MODEL_ARCHIVE_LIST,
												    RealmEmbedder,
												    RealmForOpenQA,
												    RealmKnowledgeAugEncoder,
												    RealmPreTrainedModel,
												    RealmReader,
												    RealmScorer,
												    load_tf_weights_in_realm,
												)
												from .retrieval_realm import RealmRetriever


else:
						import sys

						__A		:	Optional[int]      =		_LazyModule(__name__, globals()['''__file__'''], _import_structure, module_spec=__spec__)



