




'''simple docstring'''







import copy
import re

class 	_snake_case:
 __snake_case:							Union[str, Any]						=					'''hp'''
 __snake_case:							Any						=					{}
 __snake_case:							List[Any]						=					None






 @classmethod
 def 						_UpperCamelCase (cls       :  Optional[int]    ,		a       :  int    ,		a       :  Optional[Any]    )       ->   str:






    """simple docstring"""


    A__       =     prefix
    A__       =     defaults
    cls.build_naming_info()






 @staticmethod
 def 						_UpperCamelCase (a       :  int    ,		a       :  int    )       ->   str:






    """simple docstring"""


    if len(a    ) == 0:
       return ""
    A__       =     None
    if any(char.isdigit() for char in word    ):
       raise Exception(f"""Parameters should not contain numbers: '{word}' contains a number"""    )
    if word in info["short_word"]:
       return info["short_word"][word]
    for prefix_len in range(1    ,		len(a    ) + 1    ):
       A__       =     word[:prefix_len]
       if prefix in info["reverse_short_word"]:
          continue
       else:
          A__       =     prefix
          break

    if short_word is None:
       # Paranoid fallback
       def int_to_alphabetic(a       :  List[str]    ):
          A__       =     ''
          while integer != 0:
             A__       =     chr(ord('A'    ) + integer % 10    ) + s
             integer //= 10
          return s

       A__       =     0
       while True:
          A__       =     word + '#' + int_to_alphabetic(a    )
          if sword in info["reverse_short_word"]:
             continue
          else:
             A__       =     sword
             break

    A__       =     short_word
    A__       =     word
    return short_word






 @staticmethod
 def 						_UpperCamelCase (a       :  List[Any]    ,		a       :  Union[str, Any]    )       ->   List[str]:






    """simple docstring"""


    A__       =     param_name.split('_'    )

    A__       =     [TrialShortNamer.shortname_for_word(a    ,		a    ) for word in words]

    # We try to create a separatorless short name, but if there is a collision we have to fallback
    # to a separated short name
    A__       =     ['', '_']

    for separator in separators:
       A__       =     separator.join(a    )
       if shortname not in info["reverse_short_param"]:
          A__       =     shortname
          A__       =     param_name
          return shortname

    return param_name






 @staticmethod
 def 						_UpperCamelCase (a       :  Dict    ,		a       :  str    )       ->   List[str]:






    """simple docstring"""


    A__       =     TrialShortNamer.shortname_for_key(a    ,		a    )
    A__       =     short_name
    A__       =     param_name






 @classmethod
 def 						_UpperCamelCase (cls       :  Union[str, Any]    )       ->   Dict:






    """simple docstring"""


    if cls.NAMING_INFO is not None:
       return

    A__       =     {
        'short_word': {},
        'reverse_short_word': {},
        'short_param': {},
        'reverse_short_param': {},
    }

    A__       =     list(cls.DEFAULTS.keys()    )

    for k in field_keys:
       cls.add_new_param_name(a    ,		a    )

    A__       =     info






 @classmethod
 def 						_UpperCamelCase (cls       :  Union[str, Any]    ,		a       :  Optional[int]    )       ->   Tuple:






    """simple docstring"""


    cls.build_naming_info()
    assert cls.PREFIX is not None
    A__       =     [copy.copy(cls.PREFIX    )]

    for k, v in params.items():
       if k not in cls.DEFAULTS:
          raise Exception(f"""You should provide a default value for the param name {k} with value {v}"""    )
       if v == cls.DEFAULTS[k]:
          # The default value is not added to the name
          continue

       A__       =     cls.NAMING_INFO['short_param'][k]

       if isinstance(a    ,		a    ):
          A__       =     1 if v else 0

       A__       =     '' if isinstance(a    ,		(int, float)    ) else '-'
       A__       =     f"""{key}{sep}{v}"""
       name.append(a    )

    return "_".join(a    )






 @classmethod
 def 						_UpperCamelCase (cls       :  str    ,		a       :  Tuple    )       ->   List[str]:






    """simple docstring"""


    A__       =     repr[len(cls.PREFIX    ) + 1 :]
    if repr == "":
       A__       =     []
    else:
       A__       =     repr.split('_'    )

    A__       =     {}

    for value in values:
       if "-" in value:
          A__  ,			A__       =     value.split('-'    )
       else:
          A__       =     re.sub('[0-9.]'    ,		''    ,		a    )
          A__       =     float(re.sub('[^0-9.]'    ,		''    ,		a    )    )

       A__       =     cls.NAMING_INFO['reverse_short_param'][p_k]

       A__       =     p_v

    for k in cls.DEFAULTS:
       if k not in parameters:
          A__       =     cls.DEFAULTS[k]

    return parameters








'''simple docstring'''







def 						_A      ( UpperCAmelCase						):






   '''simple docstring'''







   A__       =     0
   while num > 0:
      digit_sum += num % 10
      num //= 10
   return digit_sum







def 						_A      ( UpperCAmelCase = 100						):






   '''simple docstring'''







   A__       =     1
   A__       =     2

   for i in range(2      ,max_n + 1						):
      A__       =     pre_numerator
      A__       =     2 * i // 3 if i % 3 == 0 else 1
      A__       =     cur_numerator
      A__       =     e_cont * pre_numerator + temp

   return sum_digits(UpperCAmelCase						)


if __name__ == "__main__":
    print(f'''{solution() = }''')


