Single and Double Underscore Naming Conventions in Python: Conventions, Interfaces, & Constants
Автор: Real Python
Загружено: 2025-02-27
Просмотров: 884
Описание:
This is a preview of the video course, "Single and Double Underscore Naming Conventions in Python". Python has a few important naming conventions that are based on using either a single or double underscore character (_). These conventions allow you to differentiate between public and non-public names in APIs, write safe classes for subclassing purposes, avoid name clashes, and more. Following and respecting these conventions allows you to write code that looks Pythonic and consistent in the eyes of other Python developers. This skill is especially useful when you’re writing code that’s intended for other developers to work with.
This is a portion of the complete course, which you can find here:
https://realpython.com/courses/single...
The rest of the course covers:
Creating a Helper Function
Avoiding a Blunder
Counting With a Variable
Moving Up to the Module
Creating a Package
Discussing Class Objects
Summarizing Examples
Importing With a Wildcard
Mangling Member Names
Learning About Dunder Methods
Avoiding Conflicts
Inspecting Other Uses
Повторяем попытку...

Доступные форматы для скачивания:
Скачать видео
-
Информация по загрузке: