






'''simple docstring'''






import itertools
import string
from collections.abc import Generator, Iterable




def        _SCREAMING_SNAKE_CASE  (				A  :       Iterable[str]  ,		A  :       int  )    -> Generator[tuple[str, ...], None, None]:







   """simple docstring"""
   __snake_case				:      Dict     							= iter(A  )
   while True:
      __snake_case				:      Dict     							= tuple(itertools.islice(A  ,		A  )  )
      if not chunk:
         return
      yield chunk




def        _SCREAMING_SNAKE_CASE  (				A  :       str  )    -> str:







   """simple docstring"""
   __snake_case				:      List[str]     							= ''.join([c.upper() for c in dirty if c in string.ascii_letters]  )
   __snake_case				:      List[Any]     							= ''

   if len(A  ) < 2:
      return dirty

   for i in range(len(A  ) - 1  ):
      clean += dirty[i]

      if dirty[i] == dirty[i + 1]:
         clean += "X"

   clean += dirty[-1]

   if len(A  ) & 1:
      clean += "X"

   return clean




def        _SCREAMING_SNAKE_CASE  (				A  :       str  )    -> list[str]:







   """simple docstring"""
   # I and J are used interchangeably to allow
   # us to use a 5x5 table (25 letters)
   __snake_case				:      List[str]     							= 'ABCDEFGHIKLMNOPQRSTUVWXYZ'
   # we're using a list instead of a '2d' array because it makes the math
   # for setting up the table and doing the actual encoding/decoding simpler
   __snake_case				:      Dict     							= []

   # copy key chars into the table if they are in `alphabet` ignoring duplicates
   for char in key.upper():
      if char not in table and char in alphabet:
         table.append(A  )

    # fill the rest of the table in with the remaining alphabet chars
   for char in alphabet:
      if char not in table:
         table.append(A  )

   return table




def        _SCREAMING_SNAKE_CASE  (				A  :       str  ,		A  :       str  )    -> str:







   """simple docstring"""
   __snake_case				:      List[Any]     							= generate_table(A  )
   __snake_case				:      Optional[int]     							= prepare_input(A  )
   __snake_case				:      List[str]     							= ''

   # https://en.wikipedia.org/wiki/Playfair_cipher#Description
   for chara, chara in chunker(A  ,		2  ):
      __snake_case							,__snake_case				:      List[str]     							= divmod(table.index(A  )  ,		5  )
      __snake_case							,__snake_case				:      Optional[int]     							= divmod(table.index(A  )  ,		5  )

      if rowa == rowa:
         ciphertext += table[rowa * 5 + (cola + 1) % 5]
         ciphertext += table[rowa * 5 + (cola + 1) % 5]
      elif cola == cola:
         ciphertext += table[((rowa + 1) % 5) * 5 + cola]
         ciphertext += table[((rowa + 1) % 5) * 5 + cola]
      else:  # rectangle
         ciphertext += table[rowa * 5 + cola]
         ciphertext += table[rowa * 5 + cola]

   return ciphertext





def        _SCREAMING_SNAKE_CASE  (				A  :       str  ,		A  :       str  )    -> str:







   """simple docstring"""
   __snake_case				:      Any     							= generate_table(A  )
   __snake_case				:      Optional[Any]     							= ''

   # https://en.wikipedia.org/wiki/Playfair_cipher#Description
   for chara, chara in chunker(A  ,		2  ):
      __snake_case							,__snake_case				:      Union[str, Any]     							= divmod(table.index(A  )  ,		5  )
      __snake_case							,__snake_case				:      Optional[int]     							= divmod(table.index(A  )  ,		5  )

      if rowa == rowa:
         plaintext += table[rowa * 5 + (cola - 1) % 5]
         plaintext += table[rowa * 5 + (cola - 1) % 5]
      elif cola == cola:
         plaintext += table[((rowa - 1) % 5) * 5 + cola]
         plaintext += table[((rowa - 1) % 5) * 5 + cola]
      else:  # rectangle
         plaintext += table[rowa * 5 + cola]
         plaintext += table[rowa * 5 + cola]

   return plaintext







'''simple docstring'''






def        _SCREAMING_SNAKE_CASE  (				A  :       list  )    -> list:







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

      for i in range(1  ,		len(A  ) - 1  ,		2  ):  # iterating over all odd indices
         if input_list[i] > input_list[i + 1]:
            __snake_case							,__snake_case				:      Tuple     							= input_list[i + 1], input_list[i]
            # swapping if elements not in order
            __snake_case				:      Any     							= False
   return input_list


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