






'''simple docstring'''

def 				snake_case       (  a_				:			list[int]						)							->					list[list[int]]:





      """simple docstring"""

      UpperCamelCase_					: int            =				[]
      if len(a_						) == 1:
            return [nums.copy()]
      for _ in range(len(a_						)						):
            UpperCamelCase_					: Any            =				nums.pop(0						)
            UpperCamelCase_					: Dict            =				permute(a_						)
            for perm in permutations:
                  perm.append(a_						)
            result.extend(a_						)
            nums.append(a_						)
      return result



def 				snake_case       (  a_				:			Any						)							->					Any:





      """simple docstring"""

      def backtrack(a_				:			int						):
            if start == len(a_						) - 1:
                  output.append(nums[:]						)
            else:
                  for i in range(a_     , len(a_						)						):
                        UpperCamelCase_     ,      UpperCamelCase_					: Any            =				nums[i], nums[start]
                        backtrack(start + 1						)
                        UpperCamelCase_     ,      UpperCamelCase_					: str            =				nums[i], nums[start]  # backtrack

      UpperCamelCase_					: Tuple            =				[]
      backtrack(0						)
      return output


if __name__ == "__main__":
      import doctest

      # use res to print the data in permute2 function
      UpperCamelCase      					=permutea([1, 2, 3])
      print(res)
      doctest.testmod()














'''simple docstring'''

def 				snake_case       (  a_				:			list						)							->					list:





      """simple docstring"""

      UpperCamelCase_					: List[str]            =				False
      while is_sorted is False:  # Until all the indices are traversed keep looping
            UpperCamelCase_					: Tuple            =				True
            for i in range(0     , len(a_						) - 1     , 2						):  # iterating over all even indices
                  if input_list[i] > input_list[i + 1]:
                        UpperCamelCase_     ,      UpperCamelCase_					: Optional[Any]            =				input_list[i + 1], input_list[i]
                        # swapping if elements not in order
                        UpperCamelCase_					: Any            =				False

            for i in range(1     , len(a_						) - 1     , 2						):  # iterating over all odd indices
                  if input_list[i] > input_list[i + 1]:
                        UpperCamelCase_     ,      UpperCamelCase_					: List[str]            =				input_list[i + 1], input_list[i]
                        # swapping if elements not in order
                        UpperCamelCase_					: Dict            =				False
      return input_list


if __name__ == "__main__":
      print("Enter list to be sorted")
      UpperCamelCase      					=[int(x) for x in input().split()]
      # inputing elements of the list in one line
      UpperCamelCase      					=odd_even_sort(input_list)
      print("The sorted list is")
      print(sorted_list)






