Skip to content

Commit 5b6ae7c

Browse files
committed
Auto-sync: 2026-02-25 15:20:45
1 parent 782ed5f commit 5b6ae7c

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

2000D.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,12 @@ void MASTER(){
3333
if(s[l] == 'L' && s[r] == 'R'){
3434
sum += pref[r] - pref[l];
3535
}
36+
if(s[l] != 'L'){
37+
l--;
38+
}
39+
if(s[r] !='R'){
40+
r--;
41+
}
3642
}
3743

3844

0 commit comments

Comments
 (0)