Why and how does C# allow accessing private variables outside the class itself when it’s within the same containing class?
See section 3.5.1 of the C# language specification. The relevant text is this: Private, which is selected by including a private modifier in the member declaration. The intuitive meaning of private is “access limited to the containing type”. Note that the modifier is relevant to the type, not the instance. And then further in section … Read more