
'''simple docstring'''






from itertools import permutations







def 		A_							(						_lowerCAmelCase :     tuple				):



      """simple docstring"""




      if num[3] % 2 != 0:
            return False

      if (num[2] + num[3] + num[4]) % 3 != 0:
            return False

      if num[5] % 5 != 0:
            return False

      _lowerCamelCase					: Dict		    = [7, 11, 13, 17]
      for i, test in enumerate(SCREAMING_SNAKE_CASE_				):
            if (num[i + 4] * 100 + num[i + 5] * 10 + num[i + 6]) % test != 0:
                  return False
      return True







def 		A_							(						_lowerCAmelCase :     int = 10				):



      """simple docstring"""




      return sum(
          int("".join(map(SCREAMING_SNAKE_CASE_					,						SCREAMING_SNAKE_CASE_				)				)				)
          for num in permutations(range(SCREAMING_SNAKE_CASE_				)				)
          if is_substring_divisible(SCREAMING_SNAKE_CASE_				)				)


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

def 	UpperCamelCase__  (     SCREAMING_SNAKE_CASE_	:	list[int]		,   SCREAMING_SNAKE_CASE_	:	int       )  ->     bool:
						_lowercase					       =					len(SCREAMING_SNAKE_CASE_       )
						_lowercase					       =					[[False] * (required_sum + 1) for _ in range(arr_len + 1       )]

						# for each arr value, a sum of zero(0) can be formed by not taking any element
						# hence True/1
						for i in range(arr_len + 1       ):
												_lowercase					       =					True

						# sum is not zero and set is empty then false
						for i in range(1		,   required_sum + 1       ):
												_lowercase					       =					False

						for i in range(1		,   arr_len + 1       ):
												for j in range(1		,   required_sum + 1       ):
																		if arr[i - 1] > j:
																								_lowercase					       =					subset[i - 1][j]
																		if arr[i - 1] <= j:
																								_lowercase					       =					subset[i - 1][j] or subset[i - 1][j - arr[i - 1]]

						return subset[arr_len][required_sum]


if __name__ == "__main__":
		import doctest

		doctest.testmod()