






"""simple docstring"""



class    lowercase__			:  # Public class to implement a graph


			def __init__(      self     :  Dict   ,       snake_case__     :  Optional[int]   ,       snake_case__     :  Tuple   ,       snake_case__     :  List[Any]					):
										lowerCamelCase_       :							str									=row
										lowerCamelCase_       :							List[str]									=col
										lowerCamelCase_       :							List[str]									=graph


			def 	UpperCAmelCase__						(      self     :  Optional[int]   ,       snake_case__     :  Any   ,       snake_case__     :  List[Any]   ,       snake_case__     :  Dict					):
										return (
										    0 <= i < self.ROW
										    and 0 <= j < self.COL
										    and not visited[i][j]
										    and self.graph[i][j]
										)


			def 	UpperCAmelCase__						(      self     :  int   ,       snake_case__     :  Optional[int]   ,       snake_case__     :  str   ,       snake_case__     :  List[str]					):
										lowerCamelCase_       :							Optional[int]									=[-1, -1, -1, 0, 0, 1, 1, 1]  # Coordinate order
										lowerCamelCase_       :							Optional[Any]									=[-1, 0, 1, -1, 1, -1, 0, 1]
										lowerCamelCase_       :							Dict									=True  # Make those cells visited
										for k in range(8					):
																	if self.is_safe(i + row_nbr[k]   ,       j + col_nbr[k]   ,       lowerCamelCase_					):
																								self.diffs(i + row_nbr[k]   ,       j + col_nbr[k]   ,       lowerCamelCase_					)


			def 	UpperCAmelCase__						(      self     :  str					):  # And finally, count all islands.
										lowerCamelCase_       :							List[str]									=[[False for j in range(self.COL					)] for i in range(self.ROW					)]
										lowerCamelCase_       :							Optional[int]									=0
										for i in range(self.ROW					):
																	for j in range(self.COL					):
																								if visited[i][j] is False and self.graph[i][j] == 1:
																															self.diffs(lowerCamelCase_   ,       lowerCamelCase_   ,       lowerCamelCase_					)
																															count += 1
										return count








import random






def     a(      A       :    Optional[Any] ,     A       :    Optional[Any] ,     A       :    str       )		->       List[Any]:
					"""simple docstring"""





					a					     =   a[left_index]
					a					     =   left_index + 1
					for j in range(left_index + 1 ,     A       ):
										if a[j] < pivot:
															a     ,				a					     =   a[i], a[j]
															i += 1
					a     ,				a					     =   a[i - 1], a[left_index]
					return i - 1






def     a(      A       :    List[Any] ,     A       :    List[Any] ,     A       :    Union[str, Any]       )		->       List[Any]:
					"""simple docstring"""





					if left < right:
										a					     =   random.randint(A ,     right - 1       )
										a     ,				a					     =   (
										    a[left],
										    a[pivot],
										)  # switches the pivot with the left most bound
										a					     =   partition(A ,     A ,     A       )
										quick_sort_random(
										    A ,     A ,     A       )  # recursive quicksort to the left of the pivot point
										quick_sort_random(
										    A ,     pivot_index + 1 ,     A       )  # recursive quicksort to the right of the pivot point






def     a(      )		->       Any:
					"""simple docstring"""





					a					     =   input("Enter numbers separated by a comma:\n"       ).strip()
					a					     =   [int(A       ) for item in user_input.split(","       )]

					quick_sort_random(A ,     0 ,     len(A       )       )

					print(A       )


if __name__ == "__main__":
				main()
