
"""simple docstring"""






def 		_snake_case			(      lowercase__						:    int						)    ->							int:


			'''simple docstring'''





			if number != int(lowercase__						):
						raise ValueError("""factorial() only accepts integral values"""						)
			if number < 0:
						raise ValueError("""factorial() not defined for negative values"""						)
			lowerCAmelCase_       :Optional[int]     	=    1
			for i in range(1 ,	number + 1						):
						value *= i
			return value






def 		_snake_case			(      lowercase__						:    int						)    ->							int:


			'''simple docstring'''





			if not isinstance(lowercase__ ,	lowercase__						):
						raise ValueError("""factorial() only accepts integral values"""						)
			if n < 0:
						raise ValueError("""factorial() not defined for negative values"""						)
			return 1 if n == 0 or n == 1 else n * factorial(n - 1						)


if __name__ == "__main__":
				import doctest

				doctest.testmod()

				__UpperCAmelCase 					=    int(input('Enter a positive integer: ').strip() or 0)
				print(F"""factorial{n} is {factorial(n)}""")








"""simple docstring"""






from __future__ import annotations






def 		_snake_case			(      lowercase__						:    list[int | float]						)    ->							int | float:


			'''simple docstring'''





			if len(lowercase__						) == 0:
						raise ValueError("""find_min() arg is an empty sequence"""						)
			lowerCAmelCase_       :Optional[int]     	=    nums[0]
			for num in nums:
						lowerCAmelCase_       :Optional[Any]     	=    min(lowercase__ ,	lowercase__						)
			return min_num


if __name__ == "__main__":
				import doctest

				doctest.testmod(verbose=True)






