(2) has multiple solutions, word links in these solutions are equally likely, and thus we merge them into a unique solution.
we take the union of the solutions and find the smallest index i l and largest index i r whose elements are 1.