def suffix_array_construction(strings):
    suffix_array = []
    for s in range(len(strings)):
        string = strings[s] + '$'
        for i in range(len(string)):
            suffix_array.append((string[i:], s, i))
    suffix_array.sort()
    return suffix_array

819d9375c7e3ec3918fbfdac1f5cd57a889c4cc5
<mask token>

def suffix_array_construction(strings):
    suffix_array = []
    for s in range(len(strings)):
        string = strings[s] + '$'
        for i in range(len(string)):
            suffix_array.append((string[i:], s, i))
    suffix_array.sort()
    return suffix_array
