






'''simple docstring'''







def  SCREAMING_SNAKE_CASE_       (UpperCamelCase      )      ->       float:
							lowerCamelCase__					:	Tuple         =       0
							while len(UpperCamelCase      ) > 1:
														lowerCamelCase__					:	Dict         =       0
														# Consider two files with minimum cost to be merged
														for _ in range(2      ):
																					lowerCamelCase__					:	Dict         =       files.index(min(UpperCamelCase      )      )
																					temp += files[min_index]
																					files.pop(UpperCamelCase      )
														files.append(UpperCamelCase      )
														optimal_merge_cost += temp
							return optimal_merge_cost


if __name__ == "__main__":
			import doctest

			doctest.testmod()








from __future__ import annotations
def      _A       (		SCREAMING_SNAKE_CASE     :   list						):





  """simple docstring"""



  if len(SCREAMING_SNAKE_CASE						) == 0:
    return []
  a__					,							a__	:					int										=min(SCREAMING_SNAKE_CASE						), max(SCREAMING_SNAKE_CASE						)
  a__	:					Optional[int]										=int(max_value - min_value						) + 1
  a__	:					list[list]										=[[] for _ in range(SCREAMING_SNAKE_CASE						)]

  for i in my_list:
    buckets[int(i - min_value						)].append(SCREAMING_SNAKE_CASE						)

  return [v for bucket in buckets for v in sorted(SCREAMING_SNAKE_CASE						)]


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

     testmod()
     assert bucket_sort([4, 5, 3, 2, 1]) == [1, 2, 3, 4, 5]
     assert bucket_sort([0, 1, -10, 15, 2, -2]) == [-10, -2, 0, 1, 2, 15]






