Dave Wilson

Greenhorn
+ Follow
since Oct 09, 2005
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Dave Wilson

Thanks for the help. I tried an array and bufferedwriter and it works.

15 years ago
In answer to your questions:


- What does in.read() do? This opens the apple.txt document and reads the contents.
- What does the line "sb.reverse().toString()" do? This reverses the first line of the document. Not exactly what I want, but if I can reverse the first line, it would be a minor success. I thought if I placed it after the in.read command it would store the reverse in the buffer and then use the next line to write it to the output file.
- What are you writing to the output file in the line "out.write(c)"? The contents of the apple.txt document

15 years ago
Sorry about the user name. I'm so used to using nicknames.
15 years ago
I have a file named apples.txt that has 3 sentences in it. The code below reads the first sentence and reverses it, but does not write the reversed sentence to the new output file. I want it to read and reverse all 3 sentences and then write the reversed sentences to the file revapples.txt. Any suggestions? Thanks.
15 years ago