This is a string reverse so it should just reverse a word you input into the string. My problem is I dont know how to input a word into the string...help please!!!
The code:
public class rev {
public static String rev (String s) {
String to_return = "";
while(true) {
if(s.equals("")) return to_return;
char c = s.charAt(0);
to_return += c;
s=s.substring(1);
}
}
}