Java Genesis

Hints for Chapter 3: Basic Programming Constructs

Problem 22: reversing a string

We can make use both of the messages that can be sent to string objects, and of string concatenation. The scenario is to

A for-loop will be needed to implement the last two steps. Try this before looking at the completed code in the next hint.


Next Hint