finished weighed and path compression
finished weighed and path compression