subject

Create a JAVA program (name your Java file as Lab2Vowels) with the following method: public static String replaceVowels(String inputString)
The method returns a new String replacing each vowel in the given String with the opposite letter. Here is how Opposite Letter works: English alphabets have 26 letters (A to Z). A is the 1st and its opposite will be 26th (i. e., Z is the first from the end). You will replace A with Z. Similarly, E is the 5th letter from the start, and it will be replaced with fifth letter from the end (i. e., V) and so on. You must not hardcode the replacement characters. Vowels may appear more than once in the same String. You should be using built-in methods of String class to find vowels and then replace them instead of using a loop. Hint: Get the appropriate index (or position) for a given vowel, then get the opposite letter using ASCII values, and then replace the vowel. Example: AAeEIooUu will return ZZvVRllFf

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 00:30
At an open or uncontrolled intersection, yield if a. your road is paved and the crossroad is not b. the cross road is paved and yours is not c. you have two or more passengers in your vehicle d. you did not yield in the last intersection
Answers: 1
question
Computers and Technology, 22.06.2019 10:00
According to alisa miller foreign news bureaus
Answers: 3
question
Computers and Technology, 22.06.2019 23:00
Which factor is the most important when choosing a website host? whether customers will make secure transactions the number of email accounts provided the purpose of the website the quality of the host control panel
Answers: 3
question
Computers and Technology, 23.06.2019 06:20
Which text function capitalizes the first letter in a string of text? question 10 options: upper capital first proper
Answers: 1
You know the right answer?
Create a JAVA program (name your Java file as Lab2Vowels) with the following method: public static...
Questions
question
Computers and Technology, 21.05.2020 04:57
question
Mathematics, 21.05.2020 04:57
question
French, 21.05.2020 04:57
question
Social Studies, 21.05.2020 04:57
Questions on the website: 13722362