If I have an array of strings such as:
string[] strArr = {"First", "Second", "Third"};
...and I want to add these to a generic List
List<string> strList = new List<string>();
what is the best way to go about it?
Option 1:
Loop with for or foreach, using .Add method.
Option 2:
.AddRange method (ref example on MSDN here):
strList.AddRange = new List<string>(strArr);
Or other options?