Wednesday, March 07, 2007

Reverse string without loops & recursion

I wanted to reverse a string in minimum steps without using loops ,recursion etc. And this is what i finally did.


string Anu = "anuviswan";
char[] Test = Anu.ToCharArray();
Array.Reverse(Test);
Anu = new string(Test);