





from __future__ import annotations



def        __lowercase       (				_SCREAMING_SNAKE_CASE			,						_SCREAMING_SNAKE_CASE     )			->       float:


      '''simple docstring'''


      SCREAMING_SNAKE_CASE		=						sorted(numsa + numsa     )
      SCREAMING_SNAKE_CASE, SCREAMING_SNAKE_CASE		=						divmod(len(_SCREAMING_SNAKE_CASE     )			,						2     )
      if mod == 1:
            return all_numbers[div]
      else:
            return (all_numbers[div] + all_numbers[div - 1]) / 2


if __name__ == "__main__":
      import doctest

      doctest.testmod()
      SCREAMING_SNAKE_CASE_						       =	[float(x) for x in input("""Enter the elements of first array: """).split()]
      SCREAMING_SNAKE_CASE_						       =	[float(x) for x in input("""Enter the elements of second array: """).split()]
      print(F'''The median of two arrays is: {median_of_two_arrays(array_a, array_a)}''')









def        __lowercase       (				_SCREAMING_SNAKE_CASE			,						_SCREAMING_SNAKE_CASE			,						_SCREAMING_SNAKE_CASE			,						_SCREAMING_SNAKE_CASE			,						_SCREAMING_SNAKE_CASE     )			->       int:


      '''simple docstring'''


      if index == number_of_items:
            return 0
      SCREAMING_SNAKE_CASE		=						0
      SCREAMING_SNAKE_CASE		=						0
      SCREAMING_SNAKE_CASE		=						knapsack(_SCREAMING_SNAKE_CASE			,						_SCREAMING_SNAKE_CASE			,						_SCREAMING_SNAKE_CASE			,						_SCREAMING_SNAKE_CASE			,						index + 1     )
      if weights[index] <= max_weight:
            SCREAMING_SNAKE_CASE		=						values[index] + knapsack(
                _SCREAMING_SNAKE_CASE			,						_SCREAMING_SNAKE_CASE			,						_SCREAMING_SNAKE_CASE			,						max_weight - weights[index]			,						index + 1     )
      return max(_SCREAMING_SNAKE_CASE			,						_SCREAMING_SNAKE_CASE     )


if __name__ == "__main__":
      import doctest

      doctest.testmod()


