
def 				a__ (				snake_case    ,       snake_case				):





  """simple docstring"""

  def get_matched_characters(snake_case    ,       snake_case				) -> str:
    __SCREAMING_SNAKE_CASE	:     Optional[Any] =						[]
    __SCREAMING_SNAKE_CASE	:     int =						min(len(_stra				)    ,       len(_stra				)				) // 2
    for i, l in enumerate(_stra				):
      __SCREAMING_SNAKE_CASE	:     Optional[int] =						int(max(0    ,       i - limit				)				)
      __SCREAMING_SNAKE_CASE	:     Any =						int(min(i + limit + 1    ,       len(_stra				)				)				)
      if l in _stra[left:right]:
        matched.append(__snake_case				)
        __SCREAMING_SNAKE_CASE	:     List[Any] =						F'''{_stra[0:_stra.index(__snake_case				)]} {_stra[_stra.index(__snake_case				) + 1:]}'''

    return "".join(__snake_case				)

  # matching characters
  __SCREAMING_SNAKE_CASE	:     Dict =						get_matched_characters(__snake_case    ,       __snake_case				)
  __SCREAMING_SNAKE_CASE	:     Any =						get_matched_characters(__snake_case    ,       __snake_case				)
  __SCREAMING_SNAKE_CASE	:     Optional[int] =						len(__snake_case				)

  # transposition
  __SCREAMING_SNAKE_CASE	:     Tuple =						(
      len([(ca, ca) for ca, ca in zip(__snake_case    ,       __snake_case				) if ca != ca]				) // 2
  )

  if not match_count:
    __SCREAMING_SNAKE_CASE	:     List[Any] =						0.0
  else:
    __SCREAMING_SNAKE_CASE	:     List[Any] =						(
        1
        / 3
        * (
            match_count / len(__snake_case				)
            + match_count / len(__snake_case				)
            + (match_count - transpositions) / match_count
        )
    )

  # common prefix up to 4 characters
  __SCREAMING_SNAKE_CASE	:     Optional[int] =						0
  for ca, ca in zip(stra[:4]    ,       stra[:4]				):
    if ca == ca:
      prefix_len += 1
    else:
      break

  return jaro + 0.1 * prefix_len * (1 - jaro)


if __name__ == "__main__":
   import doctest

   doctest.testmod()
   print(jaro_winkler("""hello""", """world"""))





"""simple docstring"""






from __future__ import annotations


def 			_lowercase				(  __snake_case					,__snake_case					,__snake_case					,__snake_case	)						->   list:
			__lowerCAmelCase      :  Dict												=       []
			__lowerCAmelCase						,	__lowerCAmelCase      :  Any												=       input_list[low:mid], input_list[mid : high + 1]
			while left and right:
						result.append((left if left[0] <= right[0] else right).pop(0	)	)
			__lowerCAmelCase      :  int												=       result + left + right
			return input_list


def 			_lowercase				(  __snake_case	)						->   list:
			if len(__snake_case	) <= 1:
						return input_list
			__lowerCAmelCase      :  int												=       list(__snake_case	)

			# iteration for two-way merging
			__lowerCAmelCase      :  Optional[int]												=       2
			while p <= len(__snake_case	):
						# getting low, high and middle value for merge-sort of single list
						for i in range(0					,len(__snake_case	)					,__snake_case	):
									__lowerCAmelCase      :  Union[str, Any]												=       i
									__lowerCAmelCase      :  Tuple												=       i + p - 1
									__lowerCAmelCase      :  Optional[Any]												=       (low + high + 1) // 2
									__lowerCAmelCase      :  Any												=       merge(__snake_case					,__snake_case					,__snake_case					,__snake_case	)
						# final merge of last two parts
						if p * 2 >= len(__snake_case	):
									__lowerCAmelCase      :  Optional[Any]												=       i
									__lowerCAmelCase      :  Union[str, Any]												=       merge(__snake_case					,0					,__snake_case					,len(__snake_case	) - 1	)
									break
						p *= 2

			return input_list


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