


'''simple docstring'''



# A Bipartite Graph is a graph whose vertices can be divided into two independent sets,
# U and V such that every edge (u, v) either connects a vertex from U to V or a vertex
# from V to U. In other words, for every edge (u, v), either u belongs to U and v to V,
# or u belongs to V and v to U. We can also say that there is no edge that connects
# vertices of same set.




def 			_a			(		_lowercase      :			Dict						):





     '''simple docstring'''






     __UpperCAmelCase			:				str													=    [False] * len(_lowercase						)
     __UpperCAmelCase			:				Any													=    [-1] * len(_lowercase						)

     def dfs(_lowercase      :			Dict    ,      _lowercase      :			List[str]						):
          __UpperCAmelCase			:				List[Any]													=    True
          __UpperCAmelCase			:				Union[str, Any]													=    c
          for u in graph[v]:
               if not visited[u]:
                    dfs(_lowercase    ,      1 - c						)

     for i in range(len(_lowercase						)						):
          if not visited[i]:
               dfs(_lowercase    ,      0						)

     for i in range(len(_lowercase						)						):
          for j in graph[i]:
               if color[i] == color[j]:
                    return False

     return True


# Adjacency list of graph
__UpperCAmelCase    :Any				       =     {0: [1, 3], 1: [0, 2], 2: [1, 3], 3: [0, 2], 4: []}

print(check_bipartite_dfs(graph))



'''simple docstring'''



def 			_a			(		_lowercase      :			List[str]						):





     '''simple docstring'''






     __UpperCAmelCase			:				int													=    len(_lowercase						)
     while cur > 1:
          # Find the maximum number in arr
          __UpperCAmelCase			:				Union[str, Any]													=    arr.index(max(arr[0:cur]						)						)
          # Reverse from 0 to mi
          __UpperCAmelCase			:				Any													=    arr[mi::-1] + arr[mi + 1 : len(_lowercase						)]
          # Reverse whole list
          __UpperCAmelCase			:				List[str]													=    arr[cur - 1 :: -1] + arr[cur : len(_lowercase						)]
          cur -= 1
     return arr


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