




import json
from typing import List, Optional, Tuple

from tokenizers import normalizers

from ...tokenization_utils_fast import PreTrainedTokenizerFast
from ...utils import logging
from .tokenization_splinter import SplinterTokenizer


UpperCamelCase__            =     logging.get_logger(__name__)

UpperCamelCase__            =     {"""vocab_file""": """vocab.txt"""}

UpperCamelCase__            =     {
    """vocab_file""": {
        """tau/splinter-base""": """https://huggingface.co/tau/splinter-base/resolve/main/vocab.txt""",
        """tau/splinter-base-qass""": """https://huggingface.co/tau/splinter-base-qass/resolve/main/vocab.txt""",
        """tau/splinter-large""": """https://huggingface.co/tau/splinter-large/resolve/main/vocab.txt""",
        """tau/splinter-large-qass""": """https://huggingface.co/tau/splinter-large-qass/resolve/main/vocab.txt""",
    }
}

UpperCamelCase__            =     {
    """tau/splinter-base""": 512,
    """tau/splinter-base-qass""": 512,
    """tau/splinter-large""": 512,
    """tau/splinter-large-qass""": 512,
}

UpperCamelCase__            =     {
    """tau/splinter-base""": {"""do_lower_case""": False},
    """tau/splinter-base-qass""": {"""do_lower_case""": False},
    """tau/splinter-large""": {"""do_lower_case""": False},
    """tau/splinter-large-qass""": {"""do_lower_case""": False},
}
class      a__       (   snake_case__ ):
						_a				:       Optional[Any]   =       VOCAB_FILES_NAMES
						_a				:       Dict   =       PRETRAINED_VOCAB_FILES_MAP
						_a				:       int   =       PRETRAINED_INIT_CONFIGURATION
						_a				:       Any   =       PRETRAINED_POSITIONAL_EMBEDDINGS_SIZES
						_a				:       List[Any]   =       SplinterTokenizer






						def __init__(  self						,     _A=None						,     _A=None						,     _A=True						,     _A="[UNK]"						,     _A="[SEP]"						,     _A="[PAD]"						,     _A="[CLS]"						,     _A="[MASK]"						,     _A="[QUESTION]"						,     _A=True						,     _A=None						,     **_A						,     ):




											"""simple docstring"""



											super().__init__(
											    _A						,     tokenizer_file=_A						,     do_lower_case=_A						,     unk_token=_A						,     sep_token=_A						,     pad_token=_A						,     cls_token=_A						,     mask_token=_A						,     tokenize_chinese_chars=_A						,     strip_accents=_A						,     additional_special_tokens=(question_token,)						,     **_A						,     )

											__lowerCAmelCase							  =			json.loads(self.backend_tokenizer.normalizer.__getstate__()     )
											if (
											    pre_tok_state.get("lowercase"						,     _A     ) != do_lower_case
											    or pre_tok_state.get("strip_accents"						,     _A     ) != strip_accents
											):
																__lowerCAmelCase							  =			getattr(_A						,     pre_tok_state.pop("type"     )     )
																__lowerCAmelCase							  =			do_lower_case
																__lowerCAmelCase							  =			strip_accents
																__lowerCAmelCase							  =			pre_tok_class(**_A     )

											__lowerCAmelCase							  =			do_lower_case






						@property
						def 							__SCREAMING_SNAKE_CASE(  self     ):




											"""simple docstring"""



											return self.convert_tokens_to_ids(self.question_token     )






						def 							__SCREAMING_SNAKE_CASE(  self						,     _A						,     _A = None     ):




											"""simple docstring"""



											if token_ids_a is None:
																return [self.cls_token_id] + token_ids_a + [self.sep_token_id]

											__lowerCAmelCase							  =			[self.cls_token_id]
											__lowerCAmelCase							  =			[self.sep_token_id]
											__lowerCAmelCase							  =			[self.question_token_id] + [self.convert_tokens_to_ids("."     )]
											if self.padding_side == "right":
																# Input is question-then-context
																return cls + token_ids_a + question_suffix + sep + token_ids_a + sep
											else:
																# Input is context-then-question
																return cls + token_ids_a + sep + token_ids_a + question_suffix + sep






						def 							__SCREAMING_SNAKE_CASE(  self						,     _A						,     _A = None     ):




											"""simple docstring"""



											__lowerCAmelCase							  =			[self.sep_token_id]
											__lowerCAmelCase							  =			[self.cls_token_id]
											__lowerCAmelCase							  =			[self.question_token_id] + [self.convert_tokens_to_ids("."     )]
											if token_ids_a is None:
																return len(cls + token_ids_a + sep     ) * [0]

											if self.padding_side == "right":
																# Input is question-then-context
																return len(cls + token_ids_a + question_suffix + sep     ) * [0] + len(token_ids_a + sep     ) * [1]
											else:
																# Input is context-then-question
																return len(cls + token_ids_a + sep     ) * [0] + len(token_ids_a + question_suffix + sep     ) * [1]






						def 							__SCREAMING_SNAKE_CASE(  self						,     _A						,     _A = None     ):




											"""simple docstring"""



											__lowerCAmelCase							  =			self._tokenizer.model.save(_A						,     name=_A     )
											return tuple(_A     )










def       _a (		SCREAMING_SNAKE_CASE_				:							int , SCREAMING_SNAKE_CASE_				:							int	):
					if a < b:
										return gcd(SCREAMING_SNAKE_CASE_ , SCREAMING_SNAKE_CASE_	)
					if a % b == 0:
										return b
					return gcd(SCREAMING_SNAKE_CASE_ , a % b	)







def       _a (		SCREAMING_SNAKE_CASE_				:							int , SCREAMING_SNAKE_CASE_				:							int , SCREAMING_SNAKE_CASE_				:							int	):
					if y == 0:
										return 1
					__lowerCAmelCase							  =			power(SCREAMING_SNAKE_CASE_ , y // 2 , SCREAMING_SNAKE_CASE_	) % mod
					__lowerCAmelCase							  =			(temp * temp) % mod
					if y % 2 == 1:
										__lowerCAmelCase							  =			(temp * x) % mod
					return temp







def       _a (		SCREAMING_SNAKE_CASE_				:							int	):
					__lowerCAmelCase							  =			2
					while b < n:
										if gcd(SCREAMING_SNAKE_CASE_ , SCREAMING_SNAKE_CASE_	) == 1 and power(SCREAMING_SNAKE_CASE_ , n - 1 , SCREAMING_SNAKE_CASE_	) != 1:
															return False
										b += 1
					return True


if __name__ == "__main__":
					UpperCamelCase__            =     int(input("""Enter number: """).strip())
					if is_carmichael_number(number):
										print(f'''{number} is a Carmichael Number.''')
					else:
										print(f'''{number} is not a Carmichael Number.''')




