Search
⌘K
Get Premium
Leetcode 3121. Count the Number of Special Characters II
Count the number of letters that appear in both lowercase and uppercase in the string and whose every lowercase occurrence appears before that letter's first uppercase occurrence. The string length can be up to 2·10^5, so an O(n) scan with per-letter tracking is expected.
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
All Regions
Comments
Hello Interview Premium
Your account is free and you can post anonymously if you choose.