Count Me In
Time limit1sMemory limit256 MB
Count the vowels and consonants in each of up to 100 given English sentences.
- Level
Easy1 of 10
- Topics
- String, Implementation
- Solved
- No attempts yet
Problem
You are given English sentences. For each sentence, count how many consonants and how many vowels it contains.
The vowels are the ten letters , , , , , , , , , . Every other letter counts as a consonant, so and are consonants because they are not in that list. Spaces count as neither.
Input
The first line has the number of sentences ().
The next lines each hold one sentence. A sentence is a list of words separated by single spaces, and each word has length between and . Every sentence holds at least one word and uses only uppercase letters, lowercase letters, and spaces. No sentence is longer than characters.
Output
For each sentence, print the number of consonants and the number of vowels in that order on one line, separated by a single space.