Company: visa_18oct
Difficulty: medium
Count Messages with Odd Length and Vowel Problem Description You're building a moderation report tool for a chat application, and part of it needs to summarize properties of the messages users have posted. Given an array of strings messages , where each entry is one user's message, count how many of those messages both have an odd length and contain at least one vowel ('a', 'e', 'i', 'o', 'u', in either uppercase or lowercase). Note: You are not expected to provide the most optimal solution, but a solution with time complexity O(messages.length * max(message.length)) will fit within the execution time limit. Examples Example 1: Input: messages = ["I", "love", "CSS", "the respects HTML"] Output: 2 Explanation: "I" has an odd length and contains a vowel. "love" has an even length. "CSS" has an odd length but contains no vowels. "the respects HTML" has an odd length (length of this string equals 17) and contains several vowels (three letters 'e'). Therefore, 2 messages meet the criteria.