Функция dir() - удобна для получения списка атрибутов у любого объекта.
Ранее я писал про функцию __dir__() в модуле (не путайте её с переменной __all__(), которая указывает список объектов для импорта если встречается конструкция from module import *).
Скорее всего вы уже знаете как использовать функцию dir(). Любой объект может реализовать метод __dir__() чтобы указать список имеющийхся и динамических атрибутов. И функция dir() поможет получить список этих атрибутов.
>>> dir(str)
['__add__', '__class__', '__contains__', ...]
У этой функции есть еще один способ применения. Её можно вызвать без аргумента, и в таком случае она вернёт список имён в текущем неймспейсе.
>>> dir()
['__builtins__', '__doc__', '__file__', ...]
>>> def test():
>>> x = 1
>>> print(dir())
>>> test()
['x']
#basic#tricks
😁Foundations Of Brazilian Jiu Jitsu No-Gi By Bernardo Faria😁
➡️With this easy-to-learn system, you will build a strong foundation tailored for No-Gi
➡️The fundamentals are the cornerstone of Jiu Jitsu, and in No-Gi, mastering the basics is what leads to victory
➡️Bernardo's game is renowned as the best for older grapplers because it is simple, easy to understand, and doesn't rely on athleticism
$99😍$9.99😍
❗️Channel Info and FAQ (MUST CHECK BEFORE BUY)❗️
📱Payment: 📱📱📱
💰Submeta FOR FREE
🌈UFC Picks
👑MasterClass
✈️@bjjfanaticsinstructionals
#BernardoFaria#BJJFanatics#NoGi#BJJ
💁♀️Buy
💁♀️
🔥NEW RELEASE🔥
😁Jiu-Jitsu For Old Guys: Guard Retention By Bernardo Faria😁
➡️Unlock the secrets to maintaining a strong guard and thriving on the mats with Bernardo Faria’s proven methods. As a 5x Black Belt World Champion, Faria has crafted this instructional specifically for older grapplers looking to retain guard with minimal energy expenditure while focusing on the fundamentals.
➡️With his in-depth understanding of leverage, timing, and the small details that make a big difference, Faria's Guard Retention series is a game-changer for older practitioners looking to elevate their Jiu-Jitsu without burning out.
➡️Whether you're a seasoned practitioner or just getting started, you'll learn how to guard with confidence and mastery, adapting the principles of BJJ to your unique body and experience level.
$197😍$19.99😍
❗️Channel Info and FAQ (MUST CHECK BEFORE BUY)❗️
📱Payment: 📱📱📱
💰Submeta FOR FREE
🌈UFC Picks
👑MasterClass
✈️@bjjfanaticsinstructionals
#BernardoFaria#BJJFanatics#Guard#Gi
💁♀️Buy
💁♀️
😁Jiu Jitsu For Old Guys: Entries For Over Under by Bernardo Faria😁
➡️Unlock the secrets to one of the most effective and accessible passing techniques in Brazilian Jiu-Jitsu with Jiu-Jitsu for Old Guys: Entries For Over Under by Bernardo Faria — 5x Black Belt World Champion, BJJ Fanatics Co-founder, and best-selling instructor.
➡️Designed specifically for older practitioners, this series emphasizes technique over athleticism, helping you maintain a competitive edge without relying on explosive power or speed
$197😍$19.99😍
❗️Channel Info and FAQ (MUST CHECK BEFORE BUY)❗️
📱Payment: 📱📱📱
💰Submeta FOR FREE
👑MasterClass
✈️@bjjfanaticsinstructionals
#BernardoFaria#Transitions#Gi#BjjFanatics
💁♀️Buy
💁♀️