






from __future__ import annotations
class 				A_     :






 '''simple docstring'''




 def __init__(						self				,	_A				,	_A)			->		Union[str, Any]:

     """simple docstring"""



     _UpperCAmelCase					:   Optional[int]      	=					text, pattern
     _UpperCAmelCase					:   Optional[Any]      	=					len(_A), len(_A)


 def 			snake_case__					(						self				,	_A)			->		int:

     """simple docstring"""



     for i in range(self.patLen - 1				,	-1				,	-1):
         if char == self.pattern[i]:
             return i
     return -1


 def 			snake_case__					(						self				,	_A)			->		int:

     """simple docstring"""



     for i in range(self.patLen - 1				,	-1				,	-1):
         if self.pattern[i] != self.text[current_pos + i]:
             return current_pos + i
     return -1


 def 			snake_case__					(						self)			->		list[int]:

     """simple docstring"""



     _UpperCAmelCase					:   int      	=					[]
     for i in range(self.textLen - self.patLen + 1):
         _UpperCAmelCase					:   List[Any]      	=					self.mismatch_in_text(_A)
         if mismatch_index == -1:
             positions.append(_A)
         else:
             _UpperCAmelCase					:   Union[str, Any]      	=					self.match_in_pattern(self.text[mismatch_index])
             _UpperCAmelCase					:   List[Any]      	=					(
                 mismatch_index - match_index
             )  # shifting index lgtm [py/multiple-definition]
     return positions



SCREAMING_SNAKE_CASE							=    'ABAABA'
SCREAMING_SNAKE_CASE							=    'AB'
SCREAMING_SNAKE_CASE							=    BoyerMooreSearch(text, pattern)
SCREAMING_SNAKE_CASE							=    bms.bad_character_heuristic()

if len(positions) == 0:
  print('No match found')
else:
  print('Pattern found in following positions: ')
  print(positions)












'''simple docstring'''





def __UpperCAmelCase   (					A					:			list		)    ->   list:
			if len(A		) <= 1:
						return lst

			UpperCAmelCase_      :       List[str]          =       1

			while i < len(A		):
						if lst[i - 1] <= lst[i]:
									i += 1
						else:
									UpperCAmelCase_    ,      UpperCAmelCase_      :       Dict          =       lst[i], lst[i - 1]
									i -= 1
									if i == 0:
												UpperCAmelCase_      :       Dict          =       1

			return lst


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


