80% FASTER || C++ || VOWEL COUNT || SIMPLE & EASY TO UNDERSTAND
\nclass Solution {\npublic:\n    long long countVowels(string word) {\n        long long int ans = 0,k=0;\n        for(int i = 0; i < word.length(); i++){\n    
```\nclass Solution {\npublic:\n    long long countVowels(string word) {\n        long long int ans = 0,k=0;\n        for(int i = 0; i < word.length(); i++){\n            if(word[i]==\'a\'||word[i]==\'e\'||word[i]==\'i\'||word[i]==\'o\'||word[i]==\'u\'){\n                k += (i+1);\n                ans = ans+k;\n            }else{\n                ans = ans+k;\n            }\n            // cout<<ans<<" ";\n        }\n        return ans;\n    }\n};\n```
['Math', 'C', 'C++']