Question: Write a class called StringAnalyzer with a main method. The program reads Strings from the user until the user enters Q. For each string, the

Write a class called StringAnalyzer with a main method. The program reads Strings from the user until the user enters "Q". For each string, the program prints "more vowels" if the number of vowels in the string is smaller than that of other characters. Otherwise, it prints "less or equal vowels". The vowels are "aeiouAEIOU". (One way to get the number of other characters is by subtracting the number of vowels from the total number of characters, the length.)

Here are sample input strings and their expected outputs:

trainee more vowels equation more vowels apple less or equal vowels abba less or equal vowels Q 

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!