We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0b77873 commit 18e0529Copy full SHA for 18e0529
Maximum score after splitting a string.cpp
@@ -2,7 +2,7 @@ class Solution {
2
public:
3
int maxScore(string s) {
4
int maxScore=0;
5
- int lzero=0,rones0;
+ int lzero=0,rones=0;
6
for(char c:s) {
7
if(c=='1') {
8
rones++;
0 commit comments