I
intruder83-help
Hi everybody.
I have a problem with sorting an array of names. I have a txt file with a
names e.g. "Jack, John, Bob, Adam, Paul".
All i have to do is write the names into the individual cells of new array
and than sort it by an alphabet using for loop and write it out into a new
txt file.
I just after figuring out how to separete a names and my source code looks
like:
string delimiter = ",";
string path = @"c:\notsorted.txt";
string r = sr.ReadLine();
string[] names = r.Split(delimiter.ToCharArray());
but i have no idea how to sort it with for loop.
If there is anyone who can help me it would be great!
Thanks
I have a problem with sorting an array of names. I have a txt file with a
names e.g. "Jack, John, Bob, Adam, Paul".
All i have to do is write the names into the individual cells of new array
and than sort it by an alphabet using for loop and write it out into a new
txt file.
I just after figuring out how to separete a names and my source code looks
like:
string delimiter = ",";
string path = @"c:\notsorted.txt";
string r = sr.ReadLine();
string[] names = r.Split(delimiter.ToCharArray());
but i have no idea how to sort it with for loop.
If there is anyone who can help me it would be great!
Thanks