





_a									=				(1, 153, 370, 371, 1_634, 24_678_051, 115_132_219_018_763_992_565_095_597_973_971_522_401)
_a									=				(-153, -1, 0, 1.2, 200, "A", [], {}, None)





def lowerCAmelCase__(__snake_case							)    ->				bool:







	'''simple docstring'''







	if not isinstance(__snake_case	,__snake_case							) or n < 1:
		return False

	# Initialization of sum and number of digits.
	lowerCamelCase__        =		0
	lowerCamelCase__        =		0
	lowerCamelCase__        =		n
	# Calculation of digits of the number
	while temp > 0:
		number_of_digits += 1
		temp //= 10
	# Dividing number into separate digits and find Armstrong number
	lowerCamelCase__        =		n
	while temp > 0:
		lowerCamelCase__        =		temp % 10
		total += rem**number_of_digits
		temp //= 10
	return n == total





def lowerCAmelCase__(__snake_case							)    ->				bool:







	'''simple docstring'''







	if not isinstance(__snake_case	,__snake_case							) or n < 1:
		return False

	# Init a "histogram" of the digits
	lowerCamelCase__        =		[0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
	lowerCamelCase__        =		0
	lowerCamelCase__        =		0
	lowerCamelCase__        =		n
	while temp > 0:
		lowerCamelCase__    ,     lowerCamelCase__        =		divmod(__snake_case	,10							)
		digit_histogram[rem] += 1
		digit_total += 1

	for cnt, i in zip(__snake_case	,range(len(__snake_case							)							)							):
		total += cnt * i**digit_total

	return n == total





def lowerCAmelCase__(__snake_case							)    ->				bool:







	'''simple docstring'''







	if not isinstance(__snake_case	,__snake_case							) or n < 1:
		return False
	lowerCamelCase__        =		len(str(__snake_case							)							)  # the power that all digits will be raised to
	# check if sum of each digit multiplied expo times is equal to number
	return n == sum(int(__snake_case							) ** expo for i in str(__snake_case							)							)





def lowerCAmelCase__()    ->				List[Any]:







	'''simple docstring'''







	lowerCamelCase__        =		int(input('''Enter an integer to see if it is an Armstrong number: '''							).strip()							)
	print(F'{num} is {"" if armstrong_number(__snake_case							) else "not "}an Armstrong number.'							)
	print(F'{num} is {"" if narcissistic_number(__snake_case							) else "not "}an Armstrong number.'							)
	print(F'{num} is {"" if pluperfect_number(__snake_case							) else "not "}an Armstrong number.'							)


if __name__ == "__main__":
			import doctest

			doctest.testmod()
			main()










import os





def lowerCAmelCase__()    ->				int:







	'''simple docstring'''







	lowerCamelCase__        =		os.path.dirname(os.path.realpath(__snake_case							)							)
	lowerCamelCase__        =		os.path.join(__snake_case	,'''triangle.txt'''							)

	with open(__snake_case							) as in_file:
		lowerCamelCase__        =		[[int(__snake_case							) for i in line.split()] for line in in_file]

	while len(__snake_case							) != 1:
		lowerCamelCase__        =		triangle.pop()
		lowerCamelCase__        =		triangle[-1]
		for j in range(len(__snake_case							) - 1							):
			curr_row[j] += max(last_row[j]	,last_row[j + 1]							)
	return triangle[0][0]


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



