版本比较
+1 −1增加 1 行删除 1 行
30 行未改动313233343535363738394030 行未改动 else { ll d = 40, res = 1; while (x && d >= 0) { res = res * tg[x][40 - d] % L; x = fa[x], -- d; x = fa[x], -- d; } cout << w[x] * res % L << endl; }}```