@artematizando · Post #3614 · 27.10.2021 г., 08:11
Yuqi #Wang, Autumn of Mountain
Hashtags
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
Пребарај: #wang
@artematizando · Post #3614 · 27.10.2021 г., 08:11
Yuqi #Wang, Autumn of Mountain
Hashtags
@Osservatorioitaliano · Post #25417 · 17.04.2026 г., 17:34
#Cina#Italia Ministro degli Esteri #Wang Yi (#PCC|Estrema sinistra): "Dall'inizio di quest'anno, i conflitti geopolitici si sono protratti e le questioni più delicate si sono inasprite, ponendo gravi sfide all'ordine internazionale e alla sicurezza globale. Sia la Cina che l'Italia sono civiltà antiche che hanno a cuore la pace e rappresentano forze importanti nel sostenere il multilateralismo. La Cina è pronta a rafforzare la comunicazione e il coordinamento con l'Italia nelle questioni internazionali e multilaterali. Riguardo alla situazione in Medioriente, Wang ha affermato che la priorità urgente è riportare gli #USA e l'#Iran al tavolo dei negoziati e cercare una soluzione politica. La Cina è pronta a mantenere la comunicazione con tutte le parti e continuerà a svolgere un ruolo costruttivo in tal senso." @OsservatorioEsteri
@Osservatorioitaliano · Post #25403 · 17.04.2026 г., 08:50
#Italia#Cina Il Ministro degli Esteri e della Cooperazione Internazionale, Antonio #Tajani (#FI|EPP): "Prima tappa a Pechino della mia missione in Cina per rilanciare il dialogo strategico a livello economico e politico. Ho presieduto con il Ministro del commercio 🇨🇳#Wang Wentao la Commissione economica mista Italia-Cina seguita dal dialogo imprenditoriale tra imprese italiane e cinesi. Oggi abbiamo raggiunto importanti nuovi risultati: da luglio inizierà la nuova tratta aerea Venezia-Pechino, siglato un piano d’azione sull’e-commerce, impostato una nuova strategia per incrementare l’export del Made in Italy in Cina con particolare riguardo al settore agroalimentare, alla meccanica e alla gioielleria. Ho avuto poi un lungo incontro con il Ministro degli Esteri #Wang Yi. Gli ho chiesto che la Cina, nel quadro del sistema multilaterale, sostenga con forza le iniziative per portare pace e stabilità in #Medioriente e #Ucraina, per mettere fine alle guerre, alle troppe morti di poveri civili innocenti e alla crisi energetica ed economica mondiale." @OsservatorioItaliano
@addisstandardeng · Post #21029 · 10.01.2026 г., 05:39
#China's top diplomat postpones visit to #Somalia, arrives in Tanzania China's top diplomat postponed what would have been a historic visit to Somalia, part of a tour of #Africa aimed at bolstering strategic trade, the East African nation's foreign affairs ministry said on Friday. #Wang Yi's planned visit would have been the first by a Chinese foreign minister since the 1980s. It had been expected to provide #Mogadishu with a diplomatic boost after #Israel became the first country to formally recognise the breakaway Republic of #Somaliland, a northern region that declared its independence in 1991. Somalia's relations with the U.S. are also at a low point after Washington said this week it would pause further assistance that benefits the government over a dispute about the demolition of a World Food Programme warehouse. Somali foreign affairs ministry officials told Reuters that the reason for the..... https://www.reuters.com/world/china/chinas-top-diplomat-wang-yi-postpones-visit-somalia-2026-01-09/
@cosplayuploadtest2 · Post #102704 · 23.03.2025 г., 03:36
Title: Kaila_Wang_The_Black_Alley_Photobook_Set.06 Authors: #None Tags: #None#The_Black_Alley#Kaila_Wang_The_Black_Alley#Kaila#Wang#The#Black#Alley#Photobook#Set #06 recommendation: None TelegraphLinks:page-0-69
@cosplayuploadtest2 · Post #102528 · 23.03.2025 г., 03:25
Title: Natalie_Wang_The_Black_Alley_Photobook_Set.99 Authors: #None Tags: #None#The_Black_Alley#Natalie_Wang_The_Black_Alley#Natalie#Wang#The#Black#Alley#Photobook#Set #99 recommendation: None TelegraphLinks:page-0-69