What
are the different access modifiers available in C#?
C# has five
different access modifiers based on which the visibility of a class or
its member is decided.
The access modifiers are mentioned below along with their scope of visibility:
private:
The members are visible only to the other members of its class
protected: The member is visible to the class in which it
belongs to. In addition, it is also accessible by all its corresponding
derived classes
internal: The member is accessible by all classes belonging
to the current project
protected internal: Both members of the current project and all
derived classes of the current class can access this member
public: The member is visible to all classes and all projects.