
"""simple docstring"""







from __future__ import annotations
def   __UpperCamelCase   (					SCREAMING_SNAKE_CASE							,    SCREAMING_SNAKE_CASE )  ->     list[list[int]]:







							"""simple docstring"""


							__snake_case     			=       []
							create_all_state(1							,    SCREAMING_SNAKE_CASE							,    SCREAMING_SNAKE_CASE							,    []							,    SCREAMING_SNAKE_CASE )
							return result
def   __UpperCamelCase   (					SCREAMING_SNAKE_CASE							,    SCREAMING_SNAKE_CASE							,    SCREAMING_SNAKE_CASE							,    SCREAMING_SNAKE_CASE							,    SCREAMING_SNAKE_CASE							,    )  ->     None:







							"""simple docstring"""


							if level == 0:
														total_list.append(current_list[:] )
														return

							for i in range(SCREAMING_SNAKE_CASE							,    total_number - level + 2 ):
														current_list.append(SCREAMING_SNAKE_CASE )
														create_all_state(i + 1							,    SCREAMING_SNAKE_CASE							,    level - 1							,    SCREAMING_SNAKE_CASE							,    SCREAMING_SNAKE_CASE )
														current_list.pop()
def   __UpperCamelCase   (					SCREAMING_SNAKE_CASE )  ->     None:







							"""simple docstring"""


							for i in total_list:
														print(*SCREAMING_SNAKE_CASE )


if __name__ == "__main__":
		_SCREAMING_SNAKE_CASE	       =      4
		_SCREAMING_SNAKE_CASE	       =      2
		_SCREAMING_SNAKE_CASE	       =      generate_all_combinations(n, k)
		print_all_state(total_list)


"""simple docstring"""







def   __UpperCamelCase   (					SCREAMING_SNAKE_CASE )  ->     list:







							"""simple docstring"""


							__snake_case     			=       len(SCREAMING_SNAKE_CASE )
							for i in range(1							,    SCREAMING_SNAKE_CASE ):
														__snake_case     			=       collection[i]
														__snake_case     			=       0
														__snake_case     			=       i - 1

														while low <= high:
																					__snake_case     			=       (low + high) // 2
																					if val < collection[mid]:
																												__snake_case     			=       mid - 1
																					else:
																												__snake_case     			=       mid + 1
														for j in range(SCREAMING_SNAKE_CASE							,    SCREAMING_SNAKE_CASE							,    -1 ):
																					__snake_case     			=       collection[j - 1]
														__snake_case     			=       val
							return collection


if __name__ == "__main__":
		_SCREAMING_SNAKE_CASE	       =      input("""Enter numbers separated by a comma:\n""").strip()
		_SCREAMING_SNAKE_CASE	       =      [int(item) for item in user_input.split(""",""")]
		print(binary_insertion_sort(unsorted))
