reverse反转的几点说明

一、要说的一点是:Array和list的反转是不同的。(附上一份解决Array反转的源地址:http://www.dotnetperls.com/reverse-string

二、

<List>的反转:http://msdn.microsoft.com/zh-cn/library/vstudio/b0axc2h2.aspx

Array的反转:()

方法一:

string[] a = {"3","a","8","haha" };
Array.Reverse(a);
foreach (string b in a)
{
Console.WriteLine(b);
}
Console.ReadKey();

方法二:

string[] a = {"3","a","8","haha" };
foreach (string b in a.Reverse())
{
Console.WriteLine(b);
}
Console.ReadKey();

posted on 2013-11-04 14:58  鸣动我心  阅读(436)  评论(0编辑  收藏  举报