I have been trying to figure out how to scramble the words in between 1st and last letters. All I have some up with is this for loop for iterating through the input.
Scanner in = new Scanner(System.in);
while(in.hasNext()){
String str = in.next();
System.out.println(str);
}
}
public void scrambler(String str){
//shuffle letters in word besides first and last
for(int i =0; i < str.length(); i++){
}
}
Aucun commentaire:
Enregistrer un commentaire