What's the point using String.ToCharArray if a string is a char array itself?

Posted by iTayb on Stack Overflow See other posts from Stack Overflow or by iTayb
Published on 2010-03-19T12:39:00Z Indexed on 2010/03/19 12:41 UTC
Read the original article Hit count: 99

Filed under:
string s = "string";
Console.WriteLine(s[1]); // returns t

char[] chars = s.ToCharArray();
Console.WriteLine(chars[1]); // also returns t

so what is the point in this method?

© Stack Overflow or respective owner

Related posts about c#