Question 1
Input: fish apple dog orange goat
Step 1: Identify vowel-starting words: apple orange
Step 2: Identify consonant-starting words: dog fish goat
Step 3: Sort each group alphabetically
Step 4: Combine (vowels first, then consonants): apple orange dog fish goat
What is the final output?
Words starting with vowels come first (sorted alphabetically), followed by words starting with consonants (sorted alphabetically): apple orange dog fish goat