





'''simple docstring'''


from __future__ import annotations

from typing import Any
class 				a_       :





					def __init__(			self		: Tuple     ,				lowercase		: int = 6						):





								"""simple docstring"""




								lowercase_      :Node | None         =			None
								lowercase_      :Node | None         =			None
								self.create_linked_list(lowercase						)





					def 							lowercase__				(			self		: int     ,				lowercase		: int						):





								"""simple docstring"""




								lowercase_      :List[Any]         =			Node()
								lowercase_      :List[Any]         =			current_node
								lowercase_      :str         =			current_node
								lowercase_      :Optional[Any]         =			current_node
								for _ in range(1     ,				lowercase						):
											lowercase_      :List[str]         =			Node()
											lowercase_      :Optional[int]         =			current_node
											lowercase_      :int         =			previous_node
											lowercase_      :str         =			current_node
								lowercase_      :Optional[Any]         =			self.front
								lowercase_      :List[Any]         =			previous_node





					def 							lowercase__				(			self		: List[str]						):





								"""simple docstring"""




								return (
								    self.front == self.rear
								    and self.front is not None
								    and self.front.data is None
								)





					def 							lowercase__				(			self		: str						):





								"""simple docstring"""




								self.check_can_perform_operation()
								return self.front.data if self.front else None





					def 							lowercase__				(			self		: str     ,				lowercase		: Any						):





								"""simple docstring"""




								if self.rear is None:
											return

								self.check_is_full()
								if not self.is_empty():
											lowercase_      :str         =			self.rear.next
								if self.rear:
											lowercase_      :List[str]         =			data





					def 							lowercase__				(			self		: Dict						):





								"""simple docstring"""




								self.check_can_perform_operation()
								if self.rear is None or self.front is None:
											return None
								if self.front == self.rear:
											lowercase_      :Tuple         =			self.front.data
											lowercase_      :Any         =			None
											return data

								lowercase_      :str         =			self.front
								lowercase_      :str         =			old_front.next
								lowercase_      :int         =			old_front.data
								lowercase_      :Optional[int]         =			None
								return data





					def 							lowercase__				(			self		: Any						):





								"""simple docstring"""




								if self.is_empty():
											raise Exception("Empty Queue"						)







					def 							lowercase__				(			self		: Optional[int]						):





								"""simple docstring"""




								if self.rear and self.rear.next == self.front:
											raise Exception("Full Queue"						)







class 				a_       :





					def __init__(			self		: Any						):





								"""simple docstring"""




								lowercase_      :Any | None         =			None
								lowercase_      :Node | None         =			None
								lowercase_      :Node | None         =			None


if __name__ == "__main__":
	import doctest

	doctest.testmod()









'''simple docstring'''


def 							UpperCAmelCase_  (						__lowerCamelCase : list			):
   if len(__lowerCamelCase			) <= 1:
      return lst

   lowercase_      :Optional[Any]         =			1

   while i < len(__lowerCamelCase			):
      if lst[i - 1] <= lst[i]:
         i += 1
      else:
         lowercase_      ,							lowercase_      :int         =			lst[i], lst[i - 1]
         i -= 1
         if i == 0:
            lowercase_      :Dict         =			1

   return lst


if __name__ == "__main__":
 lowerCAmelCase :					Any 							=input('''Enter numbers separated by a comma:\n''').strip()
 lowerCAmelCase :					List[str] 							=[int(item) for item in user_input.split(''',''')]
 print(gnome_sort(unsorted))


