Path Compression algorithm performs in which of the following operations?

Category: QuestionsPath Compression algorithm performs in which of the following operations?
Editor">Editor Staff asked 4 weeks ago

Path Compression algorithm performs in which of the following operations?
 
(a) Create operation
 
(b) Insert operation
 
(c) Find operation
 
(d) Delete operation
 
This interesting question is from Trees topic in portion Trees of Data Structures & Algorithms I
 
The question was asked by my college professor while I was bunking the class.

1 Answers
Editor">Editor Staff answered 4 weeks ago

Right choice is (c) Find operation
 
The best explanation: Path compression algorithm is performed during find operation and is independent of the strategy used to perform unions.