• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Yep I'm Back for Some Java Help :(

ChrisCramer247

Platinum Member
Just bought the Dietel and Dietel book today at the University Bookstore. Now how do I do this 🙁. I was reviewing the sample data that my Prof gave me, compiled and AGAIN her source doesn't compile. Here is the assignment online Assignment 4b. I've done part one, and three (not correct but its done), But how do I output the user entry in reverse order. I have no idea what function to use. You guys have tought me more here on the forums then I have learned in my dern class 🙂.

Thanks!
-Chris 😀
 
Chris,

Here's one way to do Part II. First off, bookmark http://java.sun.com/j2se/1.4/docs/api/index.html [java.sun.com]. The Java platform libraries Javadocs are *extremely* useful.

Every Java String type has an internal char [] buffer.

You'll get that buffer from the String, reverse the contents into a new char [] buffer. Then, construct a new String based on that buffer. Again, you'll need to confer w/ the String class Javadocs.

Simple as that.
 
Back
Top