对于以下等价类,采用“加权合并规则”(也 称“重量权衡合并规则”),进行并查运算,给出最后父结点索引序列。1-2 5-1 1-6 0-3 7-4 6-9 5-3 0-8 4–8注意:当合并大小相同的两棵树的时候,将第二棵树的根指向第一棵树的根;根结点的索引是它本身;数字之间用一个空格隔开Given the following equivalence pairs, please use the "union-by-weight rule" and the UNION/FIND algorithm to obtain the final parent node index sequence.1-2 5-1 1-6 0-3 7-4 6-9 5-3 0-8 4-8Notice: When we merge two trees with the same size, we let the root of the second tree point to the root of the first tree. The parent index of the root node is itself. Separate the numbers with only one space.