K4ziuHa [#10]
bro really thought i would spend time on a bait 😐
thats for what machines are for
Fine, I'll do it myself.
import java.util.Scanner;
public class MyProgram {
public static void main(String[] args) {
Scanner scanner = new Scanner (System.in);
System.out.println ("Enter your text:");
String message = scanner.nextLine ();
String[] vowels = {"A", "E", "I", "O", "U", "a", "e", "i", "o", "u", "1", "2", "3", "4", "5", "6", "7", "8", "9"};
String newMessage = "";
for (int i = 0; i < message.length (); i++) {
String temp = message.substring (i, i+1);
boolean vowelCheck = false;
for (int j = 0; j < vowels.length; j++) {
if (temp.equals (vowels[j])) {
vowelCheck = true;
break;
}
}
newMessage += vowelCheck ? "0" : temp;
}
System.out.println (newMessage);
}
}
// cloudberry