EASYasked at 1 company

Count the Number of Vowel Strings in Range

A easy-tier problem at 74% community acceptance, tagged with Array, String, Counting. Reported in interviews at PayPal and 0 others.

Founder's read

You've seen this one in PayPal OAs and similar assessments: given an array of strings and a range, count how many strings start and end with a vowel. It sounds trivial, which is exactly why candidates blank on it under pressure. The acceptance rate sits at 73.5 percent, meaning a quarter of test-takers either overthink it or miss an off-by-one error in the range bounds. This is a warm-up problem that trips people because they're looking for a trick that isn't there. If this hits your live assessment and you freeze on the indexing or vowel logic, StealthCoder surfaces a working solution in seconds, invisible to the proctor.

Companies asking
1
Difficulty
EASY
Acceptance
74%

Companies that ask "Count the Number of Vowel Strings in Range"

If this hits your live OA

Count the Number of Vowel Strings in Range is the kind of problem that decides whether you pass. StealthCoder reads the problem on screen and surfaces a working solution in under 2 seconds. Invisible to screen share. The proctor sees nothing. Made by an Amazon engineer who watched the leaked-problem repo become an industry secret. He decided you should have it too.

Get StealthCoder
What this means

The pattern here is pure counting: iterate through the range, check if each string's first character and last character are both vowels, increment a counter. No dynamic programming, no sorting, no hash maps. Candidates often fail because they confuse inclusive vs exclusive range bounds, or they hardcode vowels as 'aeiou' without considering uppercase. The obvious approach (check every character) is overkill, but the correct approach is even simpler: just peek at index zero and the last index. Common pitfall: treating the range as 0-indexed when the problem may use 1-indexed input, or vice versa. This is an Array and String problem that tests reading comprehension more than algorithmic depth. If you nail the boundary conditions and remember vowels are case-sensitive or not depending on the input spec, you're done in under a minute.

Pattern tags

The honest play

You know the problem. Make sure you actually pass it.

Count the Number of Vowel Strings in Range recycles across companies for a reason. It's easy-tier, and most candidates blank under the timer. StealthCoder is the hedge: an AI overlay invisible during screen share. It reads the problem and surfaces a working solution in under 2 seconds. Made by an Amazon engineer who watched the leaked-problem repo become an industry secret. He decided you should have it too. Works on HackerRank, CodeSignal, CoderPad, and Karat.

Count the Number of Vowel Strings in Range interview FAQ

Is this problem actually asked at PayPal and other companies?+

Yes, PayPal has reportedly asked it. It's categorized as an easy problem and serves as a warm-up or second-pass screening question. The low barrier to entry means it's used to filter out candidates who panic or make careless mistakes rather than to test algorithmic depth.

What's the real trick to this problem?+

There is no trick. It's a straightforward iteration and two character checks per string. Candidates often overthink it because they're expecting a trap. The only real gotchas are off-by-one errors in the range bounds and forgetting whether vowels include uppercase letters or not.

How does this relate to Array and String topics?+

It tests basic array indexing, string character access, and range slicing. You're working with an array of strings and extracting specific characters. It's foundational, not complex. The acceptance rate reflects that most candidates who approach it methodically pass.

Can I solve this in one pass?+

Yes. Loop through the range once, check the first and last character of each string, count matches. O(n) time, O(1) space. No preprocessing or secondary data structure needed. If you're writing more than five lines of logic, you've overengineered it.

What if the string is a single character?+

Edge case: a one-character string starts and ends with the same character. If that character is a vowel, it counts. Make sure your indexing handles this without crashing or double-counting. Test with 'a', 'b', etc. before submitting.

Want the actual problem statement? View "Count the Number of Vowel Strings in Range" on LeetCode →

Frequency and company-tag data sourced from public community-maintained interview-report repos. Problem, description, and trademark © LeetCode. StealthCoder is not affiliated with LeetCode.