Nowy kurs! Każdy programista powinien nauczyć się Generative AI!
Wypróbuj darmową lekcję+ 1
How to Remove vowels from a word in java
2 odpowiedzi
+ 9
str = str.toLowerCase().replaceAll("[aeiou]", "");
+ 3
if you want to keep the original string:
str = str.replaceAll("[aeiouAEIOU]", "");