mirror of
https://gitcode.com/Zengtudor/alg2025.git
synced 2025-11-07 07:13:48 +00:00
perf: 在循环内重置mcj以减少不必要的重置操作
This commit is contained in:
parent
e78435a306
commit
bdd74246a7
@ -20,8 +20,8 @@ sl void solve(){
|
||||
for(ll alen=1;alen<s.size()-1;alen++){
|
||||
maj[s[alen-1]]=maj[s[alen-1]]^1;
|
||||
for(ll blen=1;alen+blen<s.size();blen++){
|
||||
mcj.reset();
|
||||
for(ll l=1;l*(alen+blen)<s.size();l++){
|
||||
mcj.reset();
|
||||
for(ll ci=l*(alen+blen);ci<s.size();ci++){
|
||||
mcj[s[ci]]=mcj[s[ci]]^1;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user