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

TGINSIGHT SIMILAR POSTS

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

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

Оператор pipe позволяет писать более компактный код, реализуя логику объединения данных (Union). Важно помнить, что его поведение зависит от контекста. Побитовые операции (логическое OR) result = 5 | 3 # 5 (0101) | 3 (0011) = 7 (0111) Самое главное - не путать с оператором or, это другое! Объединение множеств set_a = {1, 2, 3} set_b = {3, 4, 5} set_c = set_a | set_b # {1, 2, 3, 4, 5} set_c |= {5, 6} # {1, 2, 3, 4, 5, 6} Слияние словарей dict_1 = {"a": 1, "b": 2} dict_2 = {"b": 3, "c": 4} merged = dict_1 | dict_2 # {'a': 1, 'b': 3, 'c': 4} merged |= {"d": 5} # {'a': 1, 'b': 3, 'c': 4, 'd': 5} Аннотации типов, заменяет Union def process_data(value: int | str) -> None: print(value) Допустимо использовать в isinstance или issubclass isinstance(3, int | float) # True Паттерн-матчинг status_code = 404 match status_code: case 200 | 201 | 204: print("OK") case 400 | 404 | 500: print("ERROR") Для использования в своих классах требуется переопределить метод __or__ Так же нашел библиотеку pipe которая добавляет еще много возможностей. Рекомендую ознакомиться ;) #basic

Hashtags

Резултати

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

Пребарај: #cetus

当前筛选 #cetus清除筛选
American Crypto©

@americancryptotrading · Post #27421 · 28.10.2025 г., 09:25

🇺🇸#CETUS/USDT is attempting to bounce from the supportzone on the 3D timeframe💁‍♂️ Looking for a move up📈 American Crypto©

Hashtags

Cetus Announcements

@CetusProtocol · Post #187 · 04.09.2023 г., 12:17

GREAT NEWS🎉@CetusProtocol has officially integrated @DeepBookonSui to be a part of its universal liquidity reserves🐳. Now, traders on #Cetus can enjoy further upgraded liquidity depth & slippage control powered by the seamless fusion of CLMM and CLOB.🥂 1/3🧵 https://twitter.com/CetusProtocol/status/1696197887318008148?s=20

Hashtags

Cetus Announcements

@CetusProtocol · Post #184 · 04.09.2023 г., 12:15

@CetusProtocol is very happy to have integrated 💎Coinbase Pay💎 into its user interface!🔥🎉 With this new integration to be rolled out, users on #Cetus will be given a new choice to quickly purchase crypto and easily start their exploration of DeFi. 🐳@coinbase@CoinbaseCloud https://twitter.com/CetusProtocol/status/1691766911246409975?s=20 @everyone

Hashtags

Cetus Announcements

@CetusProtocol · Post #182 · 03.08.2023 г., 06:13

It's about to enter August. Time to take a look back at what #Cetus accomplished in the past few months👇. The user-oriented product development and iteration will never stop. Keep BUIDLing & stay eager! 🚀🚀🚀 https://twitter.com/CetusProtocol/status/1686027669077417984?s=20 @everyone

Hashtags

Cetus Announcements

@CetusProtocol · Post #180 · 03.08.2023 г., 06:11

Some users may encounter slow loading during the surge in users & concurrent txns🤔. To improve experience, #Cetus now allows users to check real-time RPC node latencies in settings🚦. Users can select a node that shows better performance when they interact with the protocol.🖥🐳 https://twitter.com/CetusProtocol/status/1684832364562931712?s=20 @everyone

Hashtags

Cetus Announcements

@CetusProtocol · Post #170 · 28.06.2023 г., 18:42

We’re happy to integrate to @PythNetwork as the primary price reference source on #Cetus. Traders can have clearer references for their swap decision making. More in-depth integration & collaboration will be carried out as we continue 🔜🔜 https://twitter.com/PythNetwork/status/1674121651758448640?s=20 @everyone

Hashtags

Cetus Announcements

@CetusProtocol · Post #168 · 28.06.2023 г., 18:41

Cetus is super excited to partner with @AlchemyPay🎉🎉, a leading gateway payment provider for transacting between fiat and crypto. Users on #Cetus can now easily make credit card payment in exchange for $CETUS & other mainstream coins via Alchemy Pay. Cheers🍺. https://twitter.com/CetusProtocol/status/1673579065171906561?s=20 @everyone

Hashtags

Cetus Announcements

@CetusProtocol · Post #164 · 28.06.2023 г., 18:39

We are delighted to work with @moledefi, a Sui-based DeFi protocol that provides savings, leveraged yield farms and funds 🎉. Mole is building an one-stop solution that can help users provide liquidity to #Cetus easier and get boosted yields.🚀 https://twitter.com/moledefi/status/1668962317520998402?s=20 @everyone

Hashtags

Cetus Announcements

@CetusProtocol · Post #161 · 07.06.2023 г., 06:28

Happy to launch the Price Range Alerts on Cetus🎉 Powered by @NotifiNetwork, LPs on Cetus can receive alerts via email, sms or telegram msgs if their selected positions go out of range. #Cetus will continue bringing ease & convenience to LPs & traders.👇 https://twitter.com/cetusprotocol/status/1666330270377844736?s=46&t=IcRwi54TUHq01WguSKBieA @everyone

Hashtags

123•••910
ПретходнаСтраница 1 од 10Следна