The challenge Given a lowercase string of letters (no spaces, no digits), return the length of the longest substring that contains only vowels (aeiou). Examples: solve("codewarriors") # → 2 (the "io" in warriors) solve("suoidea") # → 3 (the "uoi") solve("aeioaexaeuoiou") # → 5 (the "aeioa" or "uoiou") solve("bcd") # → 0 solve("a") # → 1 The puzzle appears in Codewars in both Python and Java tracks. The aeioaexaeuoiou test case is the classic gotcha — make sure you handle two equally-long winners.
No comments yet. Log in to reply on the Fediverse. Comments will appear here.