Stop repeating type names when it’s obvious from context. Use target-typed new.
Verbose:
Dictionary> data = new Dictionary >(); Person person = new Person(); List names = new List () { "John", "Jane" };
Concise:
Dictionary> data = new(); Person person = new(); List names = new() { "John", "Jane" };
Type inferred from left side. Less typing, same functionality!
Works in Returns:
Person GetPerson() => new() { Name = "John", Age = 30 };
