

"""simple docstring"""






def 		A_	(   __UpperCamelCase     :				str = "mytext.txt"       ,	__UpperCamelCase     :				bool = False				):
		import socket

		lowercase										=							1_23_12  # Reserve a port for your service.
		lowercase										=							socket.socket()  # Create a socket object
		lowercase										=							socket.gethostname()  # Get local machine name
		sock.bind((host, port)				)  # Bind to the port
		sock.listen(5				)  # Now wait for client connection.

		print('''Server listening....'''				)

		while True:
				lowercase										=							sock.accept()  # Establish connection with client.
				print(f"""Got connection from {addr}"""				)
				lowercase										=							conn.recv(10_24				)
				print(f"""Server received: {data = }"""				)

				with open(snake_case_       ,	'''rb'''				) as in_file:
						lowercase										=							in_file.read(10_24				)
						while data:
								conn.send(snake_case_				)
								print(f"""Sent {data!r}"""				)
								lowercase										=							in_file.read(10_24				)

				print('''Done sending'''				)
				conn.close()
				if testing:  # Allow the test to complete
						break

		sock.shutdown(1				)
		sock.close()


if __name__ == "__main__":
							send_file()

'''simple docstring'''

def        SCREAMING_SNAKE_CASE_  (	snake_case_				:	int							)       ->	int:
 if number != int(snake_case_							):
  raise ValueError('factorial() only accepts integral values'							)
 if number < 0:
  raise ValueError('factorial() not defined for negative values'							)
 SCREAMING_SNAKE_CASE  :  str								=		1
 for i in range(1   ,     number + 1							):
  value *= i
 return value



def        SCREAMING_SNAKE_CASE_  (	snake_case_				:	int							)       ->	int:
 if not isinstance(snake_case_   ,     snake_case_							):
  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)}""")


