






def    _lowerCamelCase	(	__lowerCamelCase					)   -> int:

     '''simple docstring'''
     UpperCAmelCase__			:     Any										= str(__lowerCamelCase					).strip()
     if not oct_string:
          raise ValueError("""Empty string was passed to the function"""					)
     UpperCAmelCase__			:     Tuple										= oct_string[0] == """-"""
     if is_negative:
          UpperCAmelCase__			:     Any										= oct_string[1:]
     if not oct_string.isdigit() or not all(0 <= int(__lowerCamelCase					) <= 7 for char in oct_string					):
          raise ValueError("""Non-octal value was passed to the function"""					)
     UpperCAmelCase__			:     List[str]										= 0
     for char in oct_string:
          UpperCAmelCase__			:     Optional[Any]										= 8 * decimal_number + int(__lowerCamelCase					)
     if is_negative:
          UpperCAmelCase__			:     List[Any]										= -decimal_number
     return decimal_number


if __name__ == "__main__":
      from doctest import testmod

      testmod()














import random







class 							UpperCAmelCase_     :




     def __init__(							self  ,	_lowerCAmelCase  ,	_lowerCAmelCase		):
          UpperCAmelCase__			:     Union[str, Any]										= x
          UpperCAmelCase__			:     Union[str, Any]										= y




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




     @classmethod
     def      __UpperCAmelCase     (							cls		):
          return cls(x=random.random()  ,	y=random.random()		)





def    _lowerCamelCase	(	__lowerCamelCase					)   -> float:

     '''simple docstring'''
     if number_of_simulations < 1:
          raise ValueError("""At least one simulation is necessary to estimate PI."""					)

     UpperCAmelCase__			:     Dict										= 0
     for _ in range(__lowerCamelCase					):
          UpperCAmelCase__			:     Union[str, Any]										= 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

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






