Question: WRITE A JAVA PROGRAM . Define and write a method named countVowel that accepts only a String value as its only one parameter, and returns

WRITE A JAVA PROGRAM . Define and write a method named countVowel that accepts only a String value as its only one parameter, and returns an array of integers that are the counts of each vowels in the String. The array returned by countVowel method you will create should hold precisely 5 integers: The first is the count of As, the second is the count of Es, the third is the count of Is, the fourth is Os, and the firth if Us. For example, the call countVowel(Intelligence is the ability to adapt to change. By Stephen Hawking.) should return an array containing the value [5, 7, 6, 2, 0].

Write a main program (main method) that demonstrate countVowel in action. (Use file Vowels.java)

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!