TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
abood net
NA
7
4.4k
Problem Reversing multiple lines from a text file in C#
May 19 2011 2:45 AM
Hello everyone..
I am trying to decode the text below by reversing it.
,sdreh ni dam og yeht taht nees eb lliw ti ;sdreh ni kniht neM"
".eno yb eno dna ,ylwols sesnes rieht revocer ylno yeht elihw
yakcaM selrahC
I used this code to do it.
String reed = File.ReadAllText("DecodeThis.txt");
char[] array1 = reed.ToCharArray();
Array.Reverse(array1);
Console.WriteLine(array1);
Console.ReadLine();
the output is:
"Charles Mackay
while they only recover their senses slowly, and on by one.?
?Men think in hards: it will be seen taht they go mad in herds"
I want the output to be
" Men think in hards: it will be seen taht they go mad in herds,
while they only recover their senses slowly, and on by one.
Charles Mackay"
How can i do that? please help
Reply
Answers (
6
)
How to make a private assembly into share assembly
Problem regarding Winform and WPF