


import random







class      __lowercase  :





							"""simple docstring"""







							def __init__(	self       ,		lowerCAmelCase__       ,		lowerCAmelCase__    ):





										"""simple docstring"""




										SCREAMING_SNAKE_CASE_						:			Any       						= x
										SCREAMING_SNAKE_CASE_						:			int       						= y






							def  UpperCamelCase__			(	self    ):





										"""simple docstring"""




										return (self.x**2 + self.y**2) <= 1






							@classmethod
							def  UpperCamelCase__			(	cls    ):





										"""simple docstring"""




										return cls(x=random.random()       ,		y=random.random()    )







def 		a__       (							A__							):
			if number_of_simulations < 1:
						raise ValueError('At least one simulation is necessary to estimate PI.'							)

			SCREAMING_SNAKE_CASE_						:			List[Any]       						= 0
			for _ in range(A__							):
						SCREAMING_SNAKE_CASE_						:			List[str]       						= Point.random_unit_square()

						if random_point.is_in_unit_circle():
									number_in_unit_circle += 1

			return 4 * number_in_unit_circle / number_of_simulations


if __name__ == "__main__":
				# import doctest

				# doctest.testmod()
				from math import pi

				lowerCAmelCase__       :	List[Any]     				='Please enter the desired number of Monte Carlo simulations: '
				lowerCAmelCase__       :	str     				=estimate_pi(int(input(prompt).strip()))
				print(F"""An estimate of PI is {my_pi} with an error of {abs(my_pi - pi)}""")









def 		a__       (							A__ = 2_0							):

			try:
						SCREAMING_SNAKE_CASE_						:			Optional[Any]       						= int(A__							)
			except (TypeError, ValueError):
						raise TypeError('Parameter n must be int or castable to int.'							)
			if n <= 0:
						raise ValueError('Parameter n must be greater than or equal to one.'							)
			SCREAMING_SNAKE_CASE_						:			int       						= 0
			while 1:
						i += n * (n - 1)
						SCREAMING_SNAKE_CASE_						:			List[str]       						= 0
						for j in range(2,	A__							):
									if i % j != 0:
												SCREAMING_SNAKE_CASE_						:			str       						= 1
												break
						if nfound == 0:
									if i == 0:
												SCREAMING_SNAKE_CASE_						:			Tuple       						= 1
									return i
			return None


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





