Problem C Dist Description 有一个\(n\)个点带边权的连通无向图,边集用\(k\)个集合\(s_1,s_2,\dots,s_k\)和\(k\)个整数\(w_1,w_2,\dots,w_k\)来表示,\((s_i,w_i)\)表示\(\forall u,v\in s_i (u\not=v)\),\(\exists E(u,v)=w_i\) 求\(\sum_{i=1}^n\sum_{j=1}^{i-1}dist(i,j)\),\(dist(i,j)\)代表\(i\)点到\…