


'''simple docstring'''




import json
from typing import List, Optional, Tuple

from tokenizers import normalizers

from ...tokenization_utils_fast import PreTrainedTokenizerFast
from ...utils import logging
from .tokenization_distilbert import DistilBertTokenizer


_a   :   List[Any]												=   logging.get_logger(__name__)

_a   :   Any												=   {"vocab_file": "vocab.txt", "tokenizer_file": "tokenizer.json"}

_a   :   str												=   {
    "vocab_file": {
        "distilbert-base-uncased": "https://huggingface.co/distilbert-base-uncased/resolve/main/vocab.txt",
        "distilbert-base-uncased-distilled-squad": (
            "https://huggingface.co/distilbert-base-uncased-distilled-squad/resolve/main/vocab.txt"
        ),
        "distilbert-base-cased": "https://huggingface.co/distilbert-base-cased/resolve/main/vocab.txt",
        "distilbert-base-cased-distilled-squad": (
            "https://huggingface.co/distilbert-base-cased-distilled-squad/resolve/main/vocab.txt"
        ),
        "distilbert-base-german-cased": "https://huggingface.co/distilbert-base-german-cased/resolve/main/vocab.txt",
        "distilbert-base-multilingual-cased": (
            "https://huggingface.co/distilbert-base-multilingual-cased/resolve/main/vocab.txt"
        ),
    },
    "tokenizer_file": {
        "distilbert-base-uncased": "https://huggingface.co/distilbert-base-uncased/resolve/main/tokenizer.json",
        "distilbert-base-uncased-distilled-squad": (
            "https://huggingface.co/distilbert-base-uncased-distilled-squad/resolve/main/tokenizer.json"
        ),
        "distilbert-base-cased": "https://huggingface.co/distilbert-base-cased/resolve/main/tokenizer.json",
        "distilbert-base-cased-distilled-squad": (
            "https://huggingface.co/distilbert-base-cased-distilled-squad/resolve/main/tokenizer.json"
        ),
        "distilbert-base-german-cased": (
            "https://huggingface.co/distilbert-base-german-cased/resolve/main/tokenizer.json"
        ),
        "distilbert-base-multilingual-cased": (
            "https://huggingface.co/distilbert-base-multilingual-cased/resolve/main/tokenizer.json"
        ),
    },
}

_a   :   int												=   {
    "distilbert-base-uncased": 512,
    "distilbert-base-uncased-distilled-squad": 512,
    "distilbert-base-cased": 512,
    "distilbert-base-cased-distilled-squad": 512,
    "distilbert-base-german-cased": 512,
    "distilbert-base-multilingual-cased": 512,
}


_a   :   List[str]												=   {
    "distilbert-base-uncased": {"do_lower_case": True},
    "distilbert-base-uncased-distilled-squad": {"do_lower_case": True},
    "distilbert-base-cased": {"do_lower_case": False},
    "distilbert-base-cased-distilled-squad": {"do_lower_case": False},
    "distilbert-base-german-cased": {"do_lower_case": False},
    "distilbert-base-multilingual-cased": {"do_lower_case": False},
}




class 			_lowercase (	__lowercase							):
   _SCREAMING_SNAKE_CASE  :  int          =	VOCAB_FILES_NAMES
   _SCREAMING_SNAKE_CASE  :  Tuple          =	PRETRAINED_VOCAB_FILES_MAP
   _SCREAMING_SNAKE_CASE  :  Dict          =	PRETRAINED_POSITIONAL_EMBEDDINGS_SIZES
   _SCREAMING_SNAKE_CASE  :  List[Any]          =	PRETRAINED_INIT_CONFIGURATION
   _SCREAMING_SNAKE_CASE  :  Tuple          =	["input_ids", "attention_mask"]
   _SCREAMING_SNAKE_CASE  :  Union[str, Any]          =	DistilBertTokenizer
   def __init__(						self       :      Optional[Any]       ,   SCREAMING_SNAKE_CASE_       :      Optional[int]=None       ,   SCREAMING_SNAKE_CASE_       :      Any=None       ,   SCREAMING_SNAKE_CASE_       :      List[Any]=True       ,   SCREAMING_SNAKE_CASE_       :      Dict="[UNK]"       ,   SCREAMING_SNAKE_CASE_       :      Dict="[SEP]"       ,   SCREAMING_SNAKE_CASE_       :      List[str]="[PAD]"       ,   SCREAMING_SNAKE_CASE_       :      Optional[Any]="[CLS]"       ,   SCREAMING_SNAKE_CASE_       :      List[str]="[MASK]"       ,   SCREAMING_SNAKE_CASE_       :      str=True       ,   SCREAMING_SNAKE_CASE_       :      int=None       ,   **SCREAMING_SNAKE_CASE_       :      Any       ,   ) ->							List[str]:
        super().__init__(
            SCREAMING_SNAKE_CASE_       ,   tokenizer_file=SCREAMING_SNAKE_CASE_       ,   do_lower_case=SCREAMING_SNAKE_CASE_       ,   unk_token=SCREAMING_SNAKE_CASE_       ,   sep_token=SCREAMING_SNAKE_CASE_       ,   pad_token=SCREAMING_SNAKE_CASE_       ,   cls_token=SCREAMING_SNAKE_CASE_       ,   mask_token=SCREAMING_SNAKE_CASE_       ,   tokenize_chinese_chars=SCREAMING_SNAKE_CASE_       ,   strip_accents=SCREAMING_SNAKE_CASE_       ,   **SCREAMING_SNAKE_CASE_       ,   )

        __snake_case           =						json.loads(self.backend_tokenizer.normalizer.__getstate__()      )
        if (
            normalizer_state.get('lowercase'       ,   SCREAMING_SNAKE_CASE_      ) != do_lower_case
            or normalizer_state.get('strip_accents'       ,   SCREAMING_SNAKE_CASE_      ) != strip_accents
            or normalizer_state.get('handle_chinese_chars'       ,   SCREAMING_SNAKE_CASE_      ) != tokenize_chinese_chars
        ):
             __snake_case           =						getattr(SCREAMING_SNAKE_CASE_       ,   normalizer_state.pop('type'      )      )
             __snake_case           =						do_lower_case
             __snake_case           =						strip_accents
             __snake_case           =						tokenize_chinese_chars
             __snake_case           =						normalizer_class(**SCREAMING_SNAKE_CASE_      )

        __snake_case           =						do_lower_case
   def a  (						self       :      str       ,   SCREAMING_SNAKE_CASE_       :      str       ,   SCREAMING_SNAKE_CASE_       :      Dict=None      ) ->							Optional[Any]:
        __snake_case           =						[self.cls_token_id] + token_ids_a + [self.sep_token_id]

        if token_ids_a:
             output += token_ids_a + [self.sep_token_id]

        return output
   def a  (						self       :      int       ,   SCREAMING_SNAKE_CASE_       :      List[int]       ,   SCREAMING_SNAKE_CASE_       :      Optional[List[int]] = None      ) ->							List[int]:
        __snake_case           =						[self.sep_token_id]
        __snake_case           =						[self.cls_token_id]
        if token_ids_a is None:
             return len(cls + token_ids_a + sep      ) * [0]
        return len(cls + token_ids_a + sep      ) * [0] + len(token_ids_a + sep      ) * [1]





   def a  (						self       :      Any       ,   SCREAMING_SNAKE_CASE_       :      str       ,   SCREAMING_SNAKE_CASE_       :      Optional[str] = None      ) ->							Tuple[str]:
        __snake_case           =						self._tokenizer.model.save(SCREAMING_SNAKE_CASE_       ,   name=SCREAMING_SNAKE_CASE_      )
        return tuple(SCREAMING_SNAKE_CASE_      )








'''simple docstring'''






from __future__ import annotations

from fractions import Fraction





def lowerCamelCase__     (		__lowerCamelCase			:				int			,       __lowerCamelCase			:				int				):







   '''simple docstring'''




   return (
       num != den and num % 1_0 == den // 1_0 and (num // 1_0) / (den % 1_0) == num / den
   )





def lowerCamelCase__     (		__lowerCamelCase			:				int				):







   '''simple docstring'''




   _UpperCAmelCase  :  Optional[int]				       =[]
   _UpperCAmelCase  :  Union[str, Any]				       =1_1
   _UpperCAmelCase  :  Union[str, Any]				       =int('1' + '0' * digit_len				)
   for num in range(__lowerCamelCase			,       __lowerCamelCase				):
      while den <= 9_9:
         if (num != den) and (num % 1_0 == den // 1_0) and (den % 1_0 != 0):
            if is_digit_cancelling(__lowerCamelCase			,       __lowerCamelCase				):
               solutions.append(f"{num}/{den}"				)
         den += 1
      num += 1
      _UpperCAmelCase  :  Optional[int]				       =1_0
   return solutions





def lowerCamelCase__     (		__lowerCamelCase			:				int = 2				):







   '''simple docstring'''




   _UpperCAmelCase  :  Any				       =1.0
   for fraction in fraction_list(__lowerCamelCase				):
      _UpperCAmelCase  :  List[str]				       =Fraction(__lowerCamelCase				)
      result *= frac.denominator / frac.numerator
   return int(__lowerCamelCase				)


if __name__ == "__main__":
 print(solution())

