TGTGInsighttelegram intelligenceLIVE / telegram public index
← Python Заметки

TGINSIGHT SIMILAR POSTS

Најди сличен содржај

Изворен канал @pythonotes · Post #345 · 9 окт.

Функция 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

Резултати

Пронајдени 1 слични објави

Пребарај: #cnft

当前筛选 #cnft清除筛选

🤔What is cNFT cNFT is a young technology in TON that allows you to create NFT collections with thousands or even millions of items for the price of a single NFT mint. Using this technology, GetGems team has already conducted several NFT giveaways via the Pearls bot. For example, the Gemmy collection is a cNFT collection. 🎲 You can see the received cNFTs in your profile on #GetGems, but in order to sell or transfer such NFTs, they need to be claimed by paying a blockchain commission. 🙏 If you filled out forms from the #TONSociety, you may have already received a Soulbound #cNFT. Such cNFTs when claimed become Soulbound NFTs (#SBT) — a type of NFT that cannot be sold or transferred. These NFTs can act as an achievement or unique award that cannot be sold. ⚡️Boost | 🌐Twitter