Skip to content

Conversation

@chl131
Copy link
Contributor

@chl131 chl131 commented Nov 19, 2025

Fix typo: s.mgth() -> s.size() in 3234.Count-the-Number-of-Substrings-With-Dominant-Ones

Also, we don't need max() on line 24:

ret += extra+1;

because the if statement:

if (right[j-1] + have >= count*count)

already ensures the variable extra is non-negative.

@yangizone
Copy link

yangizone commented Nov 19, 2025 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants