C # Language Design :: Default Constrcutor for Structure

One of my colleagues mentioned that one can not add a default constructor to a structure definition. I tried that out and found that to be true. I believe it was a language design decision to have left out a default constructor from structure ADT (Abstract Data Type). But it is not a consistent design i believe, classes have default constructors so should the case be with structures. Following is the code snippet that i tried using System; using System.Collections.Generic; using System.Text; namespace DefaultConstructor { struct MyStructure { int i; public void PrintMyValue() { Console.WriteLine(” My value is “ + … Continue reading C # Language Design :: Default Constrcutor for Structure