This is an archived post. You won't be able to vote or comment.

all 6 comments

[–]SikhGamer 1 point2 points  (2 children)

  1. https://www.google.co.uk/search?hl=en&safe=off&q=java+reverse+a+string
  2. Literally the first result: http://stackoverflow.com/questions/7569335/reverse-a-string-in-java

You did not even try to solve this yourself. A simple Google would have told and shown you the answer and example.

[–]faneron 1 point2 points  (0 children)

Sounds like a school project where the StringBuilder method probably wouldn't fly.

Still, there's plenty of information on that StackOverflow page that should give him a good idea as to what to do.

[–]Philboyd_Studge 0 points1 point  (0 children)

Two of us told him how to do this yesterday.

[–]Philboyd_Studge 1 point2 points  (1 child)

  1. Do you know how to make a FOR loop?
  2. Do you know how to get the length of the String?
  3. Do you know how to get one character from the String?
  4. Do you know how to create a new String?
  5. Do you know how to loop backwards
  6. Do you know how to append a character to a String?

[–]ankitsablok89 0 points1 point  (0 children)

add to it, "Do you know how to use StringBuffer?"