subject

Write a class with a constructor that accepts a String object as its argument. The class should have a method that returns the number of vowels in the string, and another method that returns the number of consonants in the string. (Spaces count as neither vowels nor consonants and should be ignored.) Demonstrate the class in a program that performs the following steps:1. The user is asked to enter a string .
2. The program displays the following menu:
1. Count the number of vowels in the string
2. Count the number of consonants in the string
3. Count both the vowels and consonants in the string
4. Enter another string
5. Exit the program

ansver
Answers: 2

Other questions on the subject: Computers and Technology

image
Computers and Technology, 21.06.2019 13:00, ohnoitsabby5431
The documents a system at the end of the design phase, identifies any changes since the beginning of the project, and includes testing and verification of all system requirements and features. functional baseline operational baseline allocated baseline product baseline
Answers: 1
image
Computers and Technology, 22.06.2019 17:50, ImBADatmath8743
Farah works in an office with two other employees. all three share a printer and an internet connection. the utility that makes this possible is defragger quicktime soho winzip
Answers: 1
image
Computers and Technology, 23.06.2019 02:30, reyne36
Rafael needs to add a title row to a table that he has inserted in word. what should he do? use the alignment options. use the merge and center option for all the cells in the top row. use the merge and center option on the first two cells in the top row. none of the above
Answers: 3
image
Computers and Technology, 23.06.2019 10:30, tommyaberman
Would a ps4 wired controller work on an xbox one
Answers: 1
You know the right answer?
Write a class with a constructor that accepts a String object as its argument. The class should have...

Questions in other subjects:

Konu
English, 08.11.2019 11:31