






__UpperCAmelCase										=		(1, 153, 370, 371, 1634, 24678051, 115132219018763992565095597973971522401)
__UpperCAmelCase										=		(-153, -1, 0, 1.2, 200, "A", [], {}, None)




def   lowercase__   (  __snake_case					:							int						):


					'''simple docstring'''


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

					# Initialization of sum and number of digits.
					UpperCAmelCase_					:   Union[str, Any]   =		0
					UpperCAmelCase_					:   str   =		0
					UpperCAmelCase_					:   List[Any]   =		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
					UpperCAmelCase_					:   Dict   =		n
					while temp > 0:
										UpperCAmelCase_					:   Optional[int]   =		temp % 10
										total += rem**number_of_digits
										temp //= 10
					return n == total




def   lowercase__   (  __snake_case					:							int						):


					'''simple docstring'''


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

					# Init a "histogram" of the digits
					UpperCAmelCase_					:   Any   =		[0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
					UpperCAmelCase_					:   List[Any]   =		0
					UpperCAmelCase_					:   List[str]   =		0
					UpperCAmelCase_					:   Any   =		n
					while temp > 0:
										UpperCAmelCase_ ,						UpperCAmelCase_					:   Union[str, Any]   =		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   lowercase__   (  __snake_case					:							int						):


					'''simple docstring'''


					if not isinstance(__snake_case  , __snake_case						) or n < 1:
										return False
					UpperCAmelCase_					:   Optional[int]   =		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   lowercase__   (  ):


					'''simple docstring'''


					UpperCAmelCase_					:   Tuple   =		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()














from typing import TYPE_CHECKING

from ...utils import _LazyModule


__UpperCAmelCase										=		{'tokenization_phobert': ['PhobertTokenizer']}


if TYPE_CHECKING:
		from .tokenization_phobert import PhobertTokenizer

else:
		import sys

		__UpperCAmelCase										=		_LazyModule(__name__, globals()['__file__'], _import_structure, module_spec=__spec__)






