The problem is about devising an optimal strategy, to minimize the diameter of a tree by removing at most K leaves.
One of the solution greedily removed one of the end node of the current diameter, If their are several choices then one of the leaf with maximum no. of diameter starting from it,is preferred)
Can anybody explain me why this will always work..?
Thanks