






'''simple docstring'''
def  _a(  UpperCamelCase__				:						int,	UpperCamelCase__				:						int							):




      '''simple docstring'''






      while b:
            SCREAMING_SNAKE_CASE__     :				Dict							 =b, a % b
      return a





def  _a(  UpperCamelCase__				:						int,	UpperCamelCase__				:						int							):




      '''simple docstring'''






      return a if b == 0 else euclidean_gcd_recursive(UpperCamelCase__,	a % b							)





def  _a(  ):




      '''simple docstring'''






      print(f"euclidean_gcd(3, 5) = {euclidean_gcd(3,	5							)}"							)
      print(f"euclidean_gcd(5, 3) = {euclidean_gcd(5,	3							)}"							)
      print(f"euclidean_gcd(1, 3) = {euclidean_gcd(1,	3							)}"							)
      print(f"euclidean_gcd(3, 6) = {euclidean_gcd(3,	6							)}"							)
      print(f"euclidean_gcd(6, 3) = {euclidean_gcd(6,	3							)}"							)

      print(f"euclidean_gcd_recursive(3, 5) = {euclidean_gcd_recursive(3,	5							)}"							)
      print(f"euclidean_gcd_recursive(5, 3) = {euclidean_gcd_recursive(5,	3							)}"							)
      print(f"euclidean_gcd_recursive(1, 3) = {euclidean_gcd_recursive(1,	3							)}"							)
      print(f"euclidean_gcd_recursive(3, 6) = {euclidean_gcd_recursive(3,	6							)}"							)
      print(f"euclidean_gcd_recursive(6, 3) = {euclidean_gcd_recursive(6,	3							)}"							)


if __name__ == "__main__":
  main()







'''simple docstring'''
class      __SCREAMING_SNAKE_CASE      :




 def __init__(      self	:							List[Any]					,      __lowercase	:							int      )	->						None:
       SCREAMING_SNAKE_CASE__     :				Union[str, Any]									=size
       SCREAMING_SNAKE_CASE__     :				List[Any]									=[0] * size
       SCREAMING_SNAKE_CASE__     :				str									=[0] * size




 @staticmethod
 def      __magic_name__	(      __lowercase	:							int      )	->						int:
       return index | (index + 1)




 @staticmethod
 def      __magic_name__	(      __lowercase	:							int      )	->						int:
       return (index & (index + 1)) - 1




 def      __magic_name__	(      self	:							Dict					,      __lowercase	:							int					,      __lowercase	:							int      )	->						None:
       SCREAMING_SNAKE_CASE__     :				List[str]									=value
       while index < self.size:
             SCREAMING_SNAKE_CASE__     :				Any									=self.get_prev(__lowercase      ) + 1
             if current_left_border == index:
                   SCREAMING_SNAKE_CASE__     :				List[str]									=value
             else:
                   SCREAMING_SNAKE_CASE__     :				str									=max(__lowercase					,      __lowercase					,      __lowercase      )
             SCREAMING_SNAKE_CASE__     :				Optional[Any]									=self.get_next(__lowercase      )




 def      __magic_name__	(      self	:							Optional[int]					,      __lowercase	:							int					,      __lowercase	:							int      )	->						int:
       right -= 1  # Because of right is exclusive
       SCREAMING_SNAKE_CASE__     :				str									=0
       while left <= right:
             SCREAMING_SNAKE_CASE__     :				Optional[Any]									=self.get_prev(__lowercase      )
             if left <= current_left:
                   SCREAMING_SNAKE_CASE__     :				List[Any]									=max(__lowercase					,      self.tree[right]      )
                   SCREAMING_SNAKE_CASE__     :				Any									=current_left
             else:
                   SCREAMING_SNAKE_CASE__     :				Optional[Any]									=max(__lowercase					,      self.arr[right]      )
                   right -= 1
       return result


if __name__ == "__main__":
  import doctest

  doctest.testmod()