What’s the difference between an object initializer and a constructor?

What are the differences between the two and when would you use an “object initializer” over a “constructor” and vice-versa? I’m working with C#, if that matters. Also, is the object initializer method specific to C# or .NET?

7 Answers
7

Leave a Comment