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

TGINSIGHT SIMILAR POSTS

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

Изворен канал @pythonotes · Post #76 · 27 апр.

Ранее я делал серию постов про битовые операторы. Вот вам ещё один наглядный пример как это используется в Python в модуле re. Чтобы указать флаг для компилятора нам надо указать его после передаваемой строки. Например, добавляем флаг для игнорирования переноса строки. pattern = re.compile(r"(\w+)+") words = pattern.search(text, re.DOTALL) А как указать несколько флагов? Ведь явно будут ситуации когда нам потребуется больше одного. Кто читал посты по битовые операторы уже понял как. pattern.search(text, re.DOTALL | re.VERBOSE) А теперь смотрим исходники, что находится в этих атрибутах? Не удивительно, степени двойки. Почему? Потому что каждое следующее значение это сдвиг единицы влево. >>> for n in [1, 2, 4, 8, 16, 32, 64, 128, 256]: >>> print(bin(n)) 0b1 0b10 0b100 0b1000 0b10000 0b100000 0b1000000 0b10000000 0b100000000 Чтобы было понятней, давайте напишем тоже самое но иначе, добавим ведущие нули: 000000001 000000010 000000100 000001000 000010000 000100000 001000000 010000000 100000000 Не понятно что тут происходит? Читай три поста про битовые операторы начиная с этого ➡️https://t.me/pythonotes/45 В общем, это пример применения побитовых операций в самом Python. Теперь вы знаете Python еще немного лучше) #tricks#regex#libs

Резултати

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

Пребарај: #nuclearambitions

当前筛选 #nuclearambitions清除筛选
Crypto M - Crypto News

@CryptoM · Post #65275 · 12.04.2026 г., 13:14

🚀 Trump Reaffirms Iran's Nuclear Ambitions as a Red Line U.S. President Donald Trump reiterated his stance on Iran's nuclear ambitions, emphasizing it as a red line. According to BlockBeats, Trump stated that he received a comprehensive briefing from Vice President Vance, Special Envoy Whitcoff, and Kushner regarding the meeting in Islamabad. The discussions with Iran extended from early morning until late at night, lasting nearly 20 hours. Trump expressed that while he could elaborate on the meeting's details and the numerous achievements, the critical issue remains Iran's unwillingness to abandon its nuclear ambitions. He noted that the consensus reached in many areas was preferable to continuing military actions until the end. However, he stressed that these agreements are insignificant compared to the risk of nuclear power being in the hands of unpredictable individuals. Trump reiterated his long-standing position that Iran will never possess nuclear weapons, a stance he has maintained for many years. #Trump#Iran#NuclearAmbitions#RedLine#USPolitics#InternationalRelations#Diplomacy#NuclearWeapons#MiddleEast

Crypto M - Crypto News

@CryptoM · Post #65277 · 12.04.2026 г., 13:24

🚀 Polymarket Predicts WTI Crude Oil Price Surge by 2026 The probability of WTI crude oil reaching $110 by April 2026 has significantly increased on Polymarket, now standing at 67%, with a 13% rise in the last hour and a 20% increase over 24 hours. According to Odaily, the total trading volume for this event contract has surpassed $24 million. The contract stipulates that if the highest price of any one-minute candlestick for WTI crude oil futures during April 2026 equals or exceeds the listed price, the market will be deemed a 'yes'; otherwise, it will be a 'no'. Previously, the March WTI crude oil price prediction contract required the official settlement price of the active month contract on any trading day at the Chicago Mercantile Exchange to meet or exceed the listed price by the last trading day of March 2026 for a 'yes' outcome. U.S. President Donald Trump announced today that the U.S. Navy, the world's most powerful naval force, will begin blocking any vessels attempting to enter or exit the Strait of Hormuz. He also ordered the Navy to search and intercept any ships that have paid transit fees to Iran in international waters. Those who have paid such fees will not be allowed safe passage on the high seas, and efforts will begin to destroy Iranian mines in the strait. Trump warned that any Iranian who fires upon peaceful vessels will face severe consequences. He stated that Iran knows how to end the war that has devastated their country, noting the loss of their navy, air force, and defense systems, as well as the deaths of leaders including Khamenei, all due to their nuclear ambitions. The blockade is set to begin with other countries joining in, ensuring Iran does not profit from illegal extortion. Iran seeks money and, more importantly, nuclear weapons. #WTICrudeOil#OilPricePrediction#Polymarket#TradingVolume#April2026#USNavy#StraitOfHormuz#Iran#Trump#NuclearAmbitions#InternationalSecurity