Available question text
Given a binary string s (length ≤ 4×10^4), count substrings where the number of '1's is at least the square of the number of '0's. Key observation: zeros^2 grows fast, so any qualifying substring has O(√n) zeros, enabling enumeration by zero-count combined with prefix sums or two‑pointer counting for an efficient solution.
Related questions
Continue with questions that share topics or the same question type.
Sources · 1 reference
These records explain where the question appears. A company tag or candidate report does not guarantee a future interview question.
Hello Interview · 1 record
No company association
Leetcode 3234. Count the Number of Substrings With Dominant Ones
Reported date not specified · 0 source reports
Source snapshot: Nov 12, 2026
View source