Thursday, September 10, 2009

In how many ways you can create new copies of an existing string in C#?

There are two ways to create new copies of an existing string in C#:
1. Using overloaded = operator like - string s2 = s1;
2. Using the static Copy method like - string s2 = string.Copy(s1);

Share This!


No comments:

Powered By Blogger · Designed By Seo Blogger Templates