I am struggling from past week on this question, any suggestion or hint will be appreciated.
I have tree with n nodes with some stones tied on it. I want to make difference between any two adjacent node's stones as 1 or 0. I can do this adding any number of stones any number of times on any node in any order.
Idea is to minimize number of stones needed.
Image Illustration https://drive.google.com/file/d/1zR6e31Ob6Fr_LX1LbepbPUifirmGbJTk/view?usp=sharing