


'''simple docstring'''
from __future__ import annotations

# Define the Gravitational Constant G and the function
lowerCAmelCase__  =     6.67_43e-11  # unit of G : m^3 * kg^-1 * s^-2



def 				lowerCAmelCase__	(       UpperCAmelCase    ,       UpperCAmelCase    ,       UpperCAmelCase    ,       UpperCAmelCase     ):






       """simple docstring"""





       snake_case__					:	Dict          =					mass_a * mass_a

       if (force, mass_a, mass_a, distance).count(0     ) != 1:
              raise ValueError("""One and only one argument must be 0"""     )
       if force < 0:
              raise ValueError("""Gravitational force can not be negative"""     )
       if distance < 0:
              raise ValueError("""Distance can not be negative"""     )
       if mass_a < 0 or mass_a < 0:
              raise ValueError("""Mass can not be negative"""     )
       if force == 0:
              snake_case__					:	Optional[int]          =					GRAVITATIONAL_CONSTANT * product_of_mass / (distance**2)
              return {"force": force}
       elif mass_a == 0:
              snake_case__					:	Any          =					(force) * (distance**2) / (GRAVITATIONAL_CONSTANT * mass_a)
              return {"mass_1": mass_a}
       elif mass_a == 0:
              snake_case__					:	Union[str, Any]          =					(force) * (distance**2) / (GRAVITATIONAL_CONSTANT * mass_a)
              return {"mass_2": mass_a}
       elif distance == 0:
              snake_case__					:	Optional[Any]          =					(GRAVITATIONAL_CONSTANT * product_of_mass / (force)) ** 0.5
              return {"distance": distance}
       raise ValueError("""One and only one argument must be 0"""     )


# Run doctest
if __name__ == "__main__":
     import doctest

     doctest.testmod()










'''simple docstring'''





from __future__ import annotations

import sys





def UpperCAmelCase    (       UpperCAmelCase_   ,	UpperCAmelCase_						):
    # base cases
    if abs(UpperCAmelCase_						) == 1:
        return a, 0
    elif abs(UpperCAmelCase_						) == 1:
        return 0, b

    _a       , _a				:							List[Any]							       =      a, b
    _a       , _a				:							str							       =      1, 0
    _a       , _a				:							Union[str, Any]							       =      0, 1

    while remainder != 0:
        _a				:							List[Any]							       =      old_remainder // remainder
        _a       , _a				:							str							       =      remainder, old_remainder - quotient * remainder
        _a       , _a				:							Optional[Any]							       =      coeff_a, old_coeff_a - quotient * coeff_a
        _a       , _a				:							Tuple							       =      coeff_b, old_coeff_b - quotient * coeff_b

    # sign correction for negative numbers
    if a < 0:
        _a				:							Tuple							       =      -old_coeff_a
    if b < 0:
        _a				:							Any							       =      -old_coeff_b

    return old_coeff_a, old_coeff_b





def UpperCAmelCase    (       ):
    if len(sys.argv						) < 3:
        print("""2 integer arguments required"""						)
        return 1
    _a				:							Union[str, Any]							       =      int(sys.argv[1]						)
    _a				:							Any							       =      int(sys.argv[2]						)
    print(extended_euclidean_algorithm(UpperCAmelCase_   ,	UpperCAmelCase_						)						)
    return 0


if __name__ == "__main__":
  raise SystemExit(main())


