Python Classroom notes 16/Jul/2026

Access modifiers

  • Instead fo strict keywords like public, private, protected Python uses naming conventions to indicate the scope of variables and methods

  • By default, all the members in python class are public

  • The reason python doesn’t force the rules is We are all consenting adults here

  • Conventions

| Access Level | Convention | Accessibility |
| ———– | ———- | ————- |
| Public | var | Accessed from anywhere |
| Protected | _var | Intended for internal use (convention only) |
| private | __var | Internal usel triggers name mangling to prevent accidental usage|

Properties in Python Classes

Proxy-Pattern

  • Proxy is a class that acts as a stand-in or place holder for another object
  • Refer Here for the sample proxy.

By continuous learner

enthusiastic technology learner

Leave a Reply

Discover more from Direct AI Powered By Quality Thought

Subscribe now to keep reading and get access to the full archive.

Continue reading