






"""simple docstring"""
from math import radians as angle_to_radians
from math import sin

# Acceleration Constant on Earth (unit m/s^2)
A_     :					Union[str, Any]							=     9.80665






def 			lowerCamelCase_    (		_lowerCamelCase     ,  _lowerCamelCase							):

 # Ensure valid instance
 if not isinstance(_lowerCamelCase     ,  (int, float)							):
  raise TypeError('Invalid velocity. Should be a positive number.'							)

 if not isinstance(_lowerCamelCase     ,  (int, float)							):
  raise TypeError('Invalid angle. Range is 1-90 degrees.'							)

 # Ensure valid angle
 if angle > 90 or angle < 1:
  raise ValueError('Invalid angle. Range is 1-90 degrees.'							)

 # Ensure valid velocity
 if init_velocity < 0:
  raise ValueError('Invalid velocity. Should be a positive number.'							)






def 			lowerCamelCase_    (		_lowerCamelCase     ,  _lowerCamelCase							):
 check_args(_lowerCamelCase     ,  _lowerCamelCase							)
 lowerCamelCase__	:     str								=		angle_to_radians(2 * angle							)
 return round(init_velocity**2 * sin(_lowerCamelCase							) / g     ,  2							)






def 			lowerCamelCase_    (		_lowerCamelCase     ,  _lowerCamelCase							):
 check_args(_lowerCamelCase     ,  _lowerCamelCase							)
 lowerCamelCase__	:     Dict								=		angle_to_radians(_lowerCamelCase							)
 return round(init_velocity**2 * sin(_lowerCamelCase							) ** 2 / (2 * g)     ,  2							)






def 			lowerCamelCase_    (		_lowerCamelCase     ,  _lowerCamelCase							):
 check_args(_lowerCamelCase     ,  _lowerCamelCase							)
 lowerCamelCase__	:     Union[str, Any]								=		angle_to_radians(_lowerCamelCase							)
 return round(2 * init_velocity * sin(_lowerCamelCase							) / g     ,  2							)






def 			lowerCamelCase_    (		):
 lowerCamelCase__							,	lowerCamelCase__	:     List[str]								=		25, 20
 assert horizontal_distance(_lowerCamelCase     ,  _lowerCamelCase							) == 40.97
 assert max_height(_lowerCamelCase     ,  _lowerCamelCase							) == 3.73
 assert total_time(_lowerCamelCase     ,  _lowerCamelCase							) == 1.74


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

      testmod()

      # Get input from user
      A_     :					Tuple							=     float(input("Initial Velocity: ").strip())

      # Get input from user
      A_     :					int							=     float(input("angle: ").strip())

      # Print results
      print()
      print("Results: ")
      print(f"Horizontal Distance: {horizontal_distance(init_vel, angle)!s} [m]")
      print(f"Maximum Height: {max_height(init_vel, angle)!s} [m]")
      print(f"Total Time: {total_time(init_vel, angle)!s} [s]")









"""simple docstring"""
from transformers import HfArgumentParser, PyTorchBenchmark, PyTorchBenchmarkArguments






def 			lowerCamelCase_    (		):
 lowerCamelCase__	:     Tuple								=		HfArgumentParser(_lowerCamelCase							)
 try:
  lowerCamelCase__	:     Dict								=		parser.parse_args_into_dataclasses()[0]
 except ValueError as e:
  lowerCamelCase__	:     Optional[int]								=		'Arg --no_{0} is no longer used, please use --no-{0} instead.'
  lowerCamelCase__	:     Optional[Any]								=		' '.join(str(_lowerCamelCase							).split(' '							)[:-1]							)
  lowerCamelCase__	:     int								=		''
  lowerCamelCase__	:     Optional[int]								=		eval(str(_lowerCamelCase							).split(' '							)[-1]							)
  lowerCamelCase__	:     Tuple								=		[]
  for arg in depreciated_args:
   # arg[2:] removes '--'
   if arg[2:] in PyTorchBenchmarkArguments.deprecated_args:
    # arg[5:] removes '--no_'
    full_error_msg += arg_error_msg.format(arg[5:]							)
   else:
    wrong_args.append(_lowerCamelCase							)
  if len(_lowerCamelCase							) > 0:
   lowerCamelCase__	:     Optional[int]								=		full_error_msg + begin_error_msg + str(_lowerCamelCase							)
  raise ValueError(_lowerCamelCase							)

 lowerCamelCase__	:     Any								=		PyTorchBenchmark(args=_lowerCamelCase							)
 benchmark.run()


if __name__ == "__main__":
      main()

