PRO192_-_PE01_-_SU_2024_2179.webp
Vân Anh1

PRO192_-_PE01_-_SU_2024_2179.webp

Question 4:
Question 04: (03 marks)
The interface TextProcessor below is already given in Java code format, thus you can use it without creating an TextProcessor.java file:
6 of 6
Paper No: 1
<<interface>>
TextProcessor
+ remove Whitespace(input:String):String
+ countVowels(input:String):int
Write a class named TextProcessorImpl, which implements the interface TextProcessor. The class TextProcessorImpl implements all methods in TextProcessor as below:
+ remove Whitespace(input: String): String - return the string input with all whitespace characters
removed.
+ countVowels (input: String):int - return the number of vowels of the string input (no case sensitive)
Hints: You can refer to the methods: split(), contains(), indexOf(), trim(), replaceAll(), toCharArray() of the String class
Close
+ 100%
Zoom
Chưa có bình luận nào.

Thông tin

Category
PRO192
Thêm bởi
Vân Anh1
Ngày thêm
Lượt xem
3,685
Lượt bình luận
0
Rating
0.00 star(s) 0 đánh giá

Image metadata

Filename
PRO192_-_PE01_-_SU_2024_2179.webp
File size
177 KB
Dimensions
1920px x 990px

Share this media

Back
Bên trên Bottom