I\'ve just noticed that when you declare a List in c# you can put parentheses or curly braces at the end.
List myList = new List&l
They have different semantics.
List myList = new List();
The above line initializes a new List of Strings, and the () is part of the syntax of building a new object by calling its constructor with no parameters.
List myList2 = new List{};
The above line initializes a new List of Strings with the elements presented inside the {}. So, if you did List you are defining a new list with 2 elements. As you defined no elements inside the {}, it will create an empty list.
() ?That makes part of a discussion in which omitting the parenthesis in this case represents a call to the default constructor. Take a look at This Link