Search
⌘K
Get Premium
Leetcode 1456. Maximum Number of Vowels in a Substring of Given Length
Given string s and integer k, return the maximum number of vowels ('a','e','i','o','u') contained in any contiguous substring of length k. The core challenge is scanning s with a fixed-size sliding window to maintain and update the vowel count efficiently (n up to 1e5).
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.