Clear array of strings

Viewed 59794

What is the easiest way to clear an array of strings?

7 Answers

You can try this.

result = result.Where(x => !string.IsNullOrEmpty(x)).ToArray();
Related