from typing import Iterable
from typing import List


def _sort_indices(array: Iterable) -> List[int]:
    """ Returns sorting indices i of a so that sorted(a) = a[i]. """
    return [i[0] for i in sorted(enumerate(array), key=lambda x: x[1])]