# Path: py_algorithms/utils.py
# def three_way_cmp(a: Any, b: Any) -> int:
#     """Three-Way Comparison takes two values A and B belonging to a type
#         with a total order and determines whether A < B, A = B, or A > B in a
#         single operation, in accordance with the mathematical law of trichotomy.
#     """
#     return (a > b) - (a < b)


import copy
from ..utils import three_way_cmp



class SuffixArray:
    def __init__(self, string: str):
        if not string:

# Path: py_algorithms/utils.py
# def three_way_cmp(a: Any, b: Any) -> int:
#     """Three-Way Comparison takes two values A and B belonging to a type
#         with a total order and determines whether A < B, A = B, or A > B in a
#         single operation, in accordance with the mathematical law of trichotomy.
#     """
#     return (a > b) - (a < b)


# Path: py_algorithms/data_structures/suffix_array.py
import copy
from ..utils import three_way_cmp




class SuffixArray:
    def __init__(self, string: str):
        if not string:

            raise RuntimeError('Could not work with Nothing.')