"""simple docstring"""





from __future__ import annotations





def        a_  (   _lowerCAmelCase						:				list  ):





       '''simple docstring'''

       if len(_lowerCAmelCase  ) == 0:
              return []
       lowercase__    :	List[str]     					=			min(_lowerCAmelCase  ), max(_lowerCAmelCase  )
       lowercase__    :	Any     					=			int(max_value - min_value  ) + 1
       lowercase__    :	list[list]     					=			[[] for _ in range(_lowerCAmelCase  )]

       for i in my_list:
              buckets[int(i - min_value  )].append(_lowerCAmelCase  )

       return [v for bucket in buckets for v in sorted(_lowerCAmelCase  )]


if __name__ == "__main__":
       from doctest import testmod

       testmod()
       assert bucket_sort([4, 5, 3, 2, 1]) == [1, 2, 3, 4, 5]
       assert bucket_sort([0, 1, -10, 15, 2, -2]) == [-10, -2, 0, 1, 2, 15]


"""simple docstring"""





def        a_  (   _lowerCAmelCase						:				str  ):





       '''simple docstring'''

       lowercase__    :	Any     					=			[0] * len(_lowerCAmelCase  )

       for i in range(1     ,				len(_lowerCAmelCase  )  ):
              # use last results for better performance - dynamic programming
              lowercase__    :	List[str]     					=			prefix_result[i - 1]
              while j > 0 and input_string[i] != input_string[j]:
                     lowercase__    :	Dict     					=			prefix_result[j - 1]

              if input_string[i] == input_string[j]:
                     j += 1
              lowercase__    :	Union[str, Any]     					=			j

       return prefix_result





def        a_  (   _lowerCAmelCase						:				str  ):





       '''simple docstring'''

       return max(prefix_function(_lowerCAmelCase  )  )


if __name__ == "__main__":
       import doctest

       doctest.testmod()

