Hi guys,

just joined this forum and it seems to real cool place to ask some questions although they may be weird .Just new to C# .

Ok so can someone please tell me that if the main aim of the private access specifier is to protect the field from being modified by the object or other classes why do the properties allow it.

like we have some private field say int m now we declare a public property and allow it to set value of m and now the value of m can be changed by the object......so i want to know that how encapsulation concept is not violated over here .

i am new to c# so guys don't mind if i have asked something stupid and if u feel so still do reply .