'''simple docstring'''
lowercase__  :      Dict        =					[0, 2, 4, 6, 8]
lowercase__  :      str        =					[1, 3, 5, 7, 9]



def  __lowerCamelCase       (      _UpperCamelCase  :  int							,    _UpperCamelCase  :  int							,    _UpperCamelCase  :  list[int]							,    _UpperCamelCase  :  int					):


      '''simple docstring'''


      if remaining_length == 0:
            if digits[0] == 0 or digits[-1] == 0:
                  return 0

            for i in range(length // 2 - 1							,    -1							,    -1					):
                  remainder += digits[i] + digits[length - i - 1]

                  if remainder % 2 == 0:
                        return 0

                  remainder //= 10

            return 1

      if remaining_length == 1:
            if remainder % 2 == 0:
                  return 0

            UpperCAmelCase_            =  0
            for digit in range(10					):
                  UpperCAmelCase_            =  digit
                  result += reversible_numbers(
                      0							,    (remainder + 2 * digit) // 10							,    _UpperCamelCase							,    _UpperCamelCase					)
            return result

      UpperCAmelCase_            =  0
      for digita in range(10					):
            UpperCAmelCase_            =  digita

            if (remainder + digita) % 2 == 0:
                  UpperCAmelCase_            =  ODD_DIGITS
            else:
                  UpperCAmelCase_            =  EVEN_DIGITS

            for digita in other_parity_digits:
                  UpperCAmelCase_            =  digita
                  result += reversible_numbers(
                      remaining_length - 2							,    (remainder + digita + digita) // 10							,    _UpperCamelCase							,    _UpperCamelCase							,    )
      return result



def  __lowerCamelCase       (      _UpperCamelCase  :  int = 9					):


      '''simple docstring'''


      UpperCAmelCase_            =  0
      for length in range(1							,    max_power + 1					):
            result += reversible_numbers(_UpperCamelCase							,    0							,    [0] * length							,    _UpperCamelCase					)
      return result


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






'''simple docstring'''
import re



def  __lowerCamelCase       (      _UpperCamelCase  :  str					):


      '''simple docstring'''


      return [char.split() for char in re.split(R'''[^ a-z A-Z 0-9 \s]'''							,    str_					)]



def  __lowerCamelCase       (      _UpperCamelCase  :  str					):


      '''simple docstring'''


      UpperCAmelCase_            =  split_input(str_					)
      return "".join(
          [''''''.join([char.capitalize() for char in sub_str]					) for sub_str in string_split]					)



def  __lowerCamelCase       (      _UpperCamelCase  :  str							,    _UpperCamelCase  :  bool							,    _UpperCamelCase  :  str					):


      '''simple docstring'''


      try:
            UpperCAmelCase_            =  split_input(_UpperCamelCase					)
            if upper:
                  UpperCAmelCase_            =  ''''''.join(
                      [
                          separator.join([char.upper() for char in sub_str]					)
                          for sub_str in string_split
                      ]					)
            else:
                  UpperCAmelCase_            =  ''''''.join(
                      [
                          separator.join([char.lower() for char in sub_str]					)
                          for sub_str in string_split
                      ]					)
            return res_str
      except IndexError:
            return "not valid string"



def  __lowerCamelCase       (      _UpperCamelCase  :  str					):


      '''simple docstring'''


      return to_simple_case(_UpperCamelCase					)



def  __lowerCamelCase       (      _UpperCamelCase  :  str					):


      '''simple docstring'''


      try:
            UpperCAmelCase_            =  to_simple_case(_UpperCamelCase					)
            return res_str[0].lower() + res_str[1:]
      except IndexError:
            return "not valid string"



def  __lowerCamelCase       (      _UpperCamelCase  :  str							,    _UpperCamelCase  :  bool					):


      '''simple docstring'''


      return to_complex_case(_UpperCamelCase							,    _UpperCamelCase							,    '''_'''					)



def  __lowerCamelCase       (      _UpperCamelCase  :  str							,    _UpperCamelCase  :  bool					):


      '''simple docstring'''


      return to_complex_case(_UpperCamelCase							,    _UpperCamelCase							,    '''-'''					)


if __name__ == "__main__":
      __import__("doctest").testmod()





