AtCoder Beginner Contest 264 G.String Fair(最短路/暴力dp 补写法)
题目n(nusingnamespacestd;#definefifirst#definesesecondtypedeflonglongll;typedefpairP;constintN=27*27,M=N*27;intn,u,v,w,cnt[N];lldis[N],a[M],mx;strings;boolvis[N];intf(stringx){intn=x.size(),ans=0;for(in