If x ' s ▁ rank ▁ is ▁ less ▁ than ▁ y ' s rank Then move x under y so that depth of tree remains less
if self . rank [ xRoot ] < self . rank [ yRoot ] : NEW_LINE INDENT parent [ xRoot ] = yRoot NEW_LINE DEDENT