1package String;
2
3public class VowelswithStar
4{
5
6 public static void main(String[] args)
7 {
8 String string = "Welcome to Candid Java Programming"; //Input String
9 System.out.println("Input String : "+string); //Displaying Input String
10 string = string.replaceAll("[aeiou]", "x"); //Replace vowels with star
11 System.out.println(string); //Display the word after replacement
12
13 }
14
15}
1Input String : The quick brown fox jumps over the lazy dog
2Thx qxxck brxwn fxx jxmps xvxr thx lxzy dxg