there is a country which contains n cities connected by n - 1 roads(just like a tree). If you place TNT in one city, all the roads connect these city will be destroyed, now i want to destroy all the roads with the least number of TNT, can you help me ?
2 5 1 2 2 3 3 4 4 5
2
无
Alex@NBUT