版本比较
+2 −2增加 2 行删除 2 行
44 行未改动45464748494950515253545555565758596044 行未改动 cnt[s]++; pos[s] = i; } cout << ans << endl;} signed main(){ ios::sync_with_stdio(0); cin.tie(0), cout.tie(0); //cin >> TT; while (TT--) while (TT--) solve(); return 0;}```