In a recent past there has been a lot of talk about whats new in C# 6.0
One of the most talked about feature is using Dictionary initializers in C# 6.0
New is creating a dictionary this way
Dictionary myDict = new Dictionary() {
[1] = "Pankaj",
[2] = "Pankaj",
[3] = "Pankaj"
};
with the style of
Obsolete: string indexed member syntax (as stated in the comments)
Dictionary myDict = new Dictionary() {
$1 = "Pankaj",
$2 = "Pankaj",
$3 = "Pankaj"
};
Taken from A C# 6.0 Language Preview
To understand the $ operator, take a look at the AreEqual function call. Notice the Dictionary member invocation of “$Boolean” on the builtInDataTypes variable—even though there’s no “Boolean” member on Dictionary. Such an explicit member isn’t required because the $ operator invokes the indexed member on the dictionary, the equivalent of calling buildInDataTypes["Boolean"].