
"""simple docstring"""







def     __lowerCAmelCase				(_UpperCamelCase       ,  _UpperCamelCase       ,  _UpperCamelCase		):
	if principal <= 0:
		raise Exception('Principal borrowed must be > 0'		)
	if rate_per_annum < 0:
		raise Exception('Rate of interest must be >= 0'		)
	if years_to_repay <= 0 or not isinstance(_UpperCamelCase       ,  _UpperCamelCase		):
		raise Exception('Years to repay must be an integer > 0'		)

	# Yearly rate is divided by 12 to get monthly rate
	__lowerCAmelCase			:						Optional[Any]									=      rate_per_annum / 12

	# Years to repay is multiplied by 12 to get number of payments as payment is monthly
	__lowerCAmelCase			:						str									=      years_to_repay * 12

	return (
	    principal
	    * rate_per_month
	    * (1 + rate_per_month) ** number_of_payments
	    / ((1 + rate_per_month) ** number_of_payments - 1)
	)


if __name__ == "__main__":
							import doctest

							doctest.testmod()







"""simple docstring"""



def 						_SCREAMING_SNAKE_CASE (    __snake_case			:  int    ):





  '''simple docstring'''





  return sum(i for i in range(1		,					number // 2 + 1    ) if number % i == 0    ) == number


if __name__ == "__main__":
    print('Program to check whether a number is a Perfect number or not...')
    _UpperCamelCase		:  Tuple						=		int(input('Enter number: ').strip())
    print(F'''{number} is {'' if perfect(number) else 'not '}a Perfect Number.''')


