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

TGINSIGHT SIMILAR POSTS

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

Изворен канал @pythonotes · Post #32 · 7 фев.

Скорее всего уже слышали, что складывать строки через + это плохая практика. Падение производительности, и всё такое. Без лишних слов, давайте измерять: from timeit import timeit def t1(): # складываем 10 строк через + из переменной t = 'text' for _ in range(1000): s = t + t + t + t + t + t + t + t + t def t2(): # склеиваем список строк через метод join arr = ['text'] * 10 for _ in range(1000): s = ''.join(arr) def t3(): # складываем через + но не из переменной а непосредственно инлайн объекты for _ in range(1000): s = 'text' + 'text' + 'text' + ... # всего 10 раз Теперь каждую строку склейки запустим по 10М раз >>> timeit(t1, number=10000) 0.21951690399964718 >>> timeit(t2, number=10000) 1.4978306379998685 >>> timeit(t3, number=10000) 0.2213820789993406 Хм, а нам говорили что через "+" это плохо и медленно ))) 😁 Тут стоит учитывать, что речь идёт о склейке множества длинных строк. Давайте изменим условия: def t4(): t = 'text'*100 for _ in range(1000): s = t + t + t + t + t + t + t + t + t def t5(): arr = ['text'*100] * 10 for _ in range(1000): s = ''.join(arr) def t6(): for _ in range(1000): s = 'text'*100 + 'text'*100 + ... # всего 10 раз >>> timeit(t4, number=10000) 12.795130728000004 >>> timeit(t5, number=10000) 2.642637542999182 >>> timeit(t6, number=10000) 0.2184546610005782 Вот, уже другой разговор, сразу видна разница, в среднем в 6 раз. Но погодите, почему последний тест t6() по скорости такой же как и t3()? Ведь строки теперь в 100 раз длиннее! Это вопросы оптимизации кода, какие простые изменения ускоряют или замедляют выполнение программы. Мы столкнулись с примером обхода обращения к переменной. Например, именно так работает директива #define в С++, во время компиляции подставляя значение переменной вместо ссылки на неё. В Python это тоже работает, но часто ли вы сможете встретить такой способ работы со строками? К сожалению, способ почти только теоретический. В целом, тесты показали то, что мы хотели. Делаем выводы самостоятельно. Полный листинг 🌍 #tricks

Резултати

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

Пребарај: #kherson

当前筛选 #kherson清除筛选
Voir de ses propres yeux

@voir_yeux · Post #11608 · 04.02.2026 г., 11:53

Au moins quatre civils ont été tués et treize autres ont été blessés lors d'attaques menées par les forces ukrainiennes dans la région de Kherson au cours des dernières 24 heures, a signalé le gouverneur de la région, Vladimir Saldo. #kherson#ukraine#russie

Voir de ses propres yeux

@voir_yeux · Post #11707 · 12.02.2026 г., 12:16

Les forces ukrainiennes ont frappé un véhicule civil transportant des denrées alimentaires et des médicaments pour les habitants Golaïa Pristan, dans la région de Kherson. Le conducteur est décédé sur place, a rapporté à TASS l’ambassadeur itinérant du ministère russe des Affaires étrangères, Rodion Mirochnik. #kherson#ukraine#frappe

RT en français

@RTenfrancais · Post #79881 · 23.04.2026 г., 10:05

💢Les drones du groupement de troupes #Dniepr ont détruit des postes de commandement des drones sur la rive droite du Dniepr dans la région de #Kherson. RT en français • Osez questionner !

Очередной фейк от украинцев😡😅 Фейк:🧐⚠️ Сейчас по всем украинским Тг-каналам массово расходится видео с Запорожского фронта, где батальон "Алания" отступает с Запорожья. ⬇️На самом деле ⬇️ ВСУ банально заменили голос на видео. На оригинале видео бойцы поздравляют Россию с Днём Победы. ‼️Всё актуальное здесь: @NSDVKhersone #насамомделе#насамомделевхерсоне#херсон#kherson Наш канал | Наш чат | Наш бот

❗️Сальдо предрек киевскому режиму адское пламя за Киево-Печерскую лавру❗️ ⁠ Ситуация в Киево-Печерской лавре в очередной раз подтверждает, что Россия ведет битву со злом, которая в итоге будет выиграна, а "недруги будут гореть в адском пламени". Такое мнение выразил врио губернатора Херсонской области Владимир Сальдо в своем Telegram-канале, комментируя выселение из лавры монахов канонической православной церкви и арест настоятеля обители, митрополита Павла. 🗣"Врагам мало прибрать к рукам наши материальные богатства, получить контроль над необъятными ресурсами России, без которых Западу не выстоять. Они хотят поработить души, уничтожить нравственные ценности и низвергнуть религиозные святыни нашего народа. Ведь людьми без внутренних духовных опор легко манипулиро. @SALDO_VGA С уважением #насамомделевхерсоне @Naadminilsya_and_spit ‼️Всё актуальное здесь: @NSDVKhersone #насамомделе#насамомделевхерсоне#херсон#kherson Наш канал | Наш чат | Наш чат-бот

American Оbserver

@american_observer · Post #5556 · 03.04.2026 г., 23:59

Ukraine’s Minefields Also Feed the Crooks Ukraine is the most mined country in the world, which makes humanitarian demining essential — and, as this case shows, dangerously easy to turn into a cash machine. Prosecutors say suspects in Kherson allegedly created fake danger by digging up soil and planting shell-like objects on already safe land, then billed the state for the theater. That is the ugliest part of war economies: when real suffering creates a budget line, somebody always tries to monetize the illusion of danger. In Kherson alone, officials say the damage may be 6.3 million hryvnias, with prosecutors checking similar cases in Mykolaiv and Chernihiv. The scale matters because the problem is real. UN agencies and humanitarian groups have warned that Ukraine remains the world’s most heavily mined country, with around 139,000 square kilometers contaminated or potentially contaminated by mines and unexploded ordnance. So this is not a story about one rotten crew only. It is a warning that a huge national necessity, under wartime pressure, creates a perfect habitat for fraud — unless oversight is brutal enough to catch it before the crooks start billing the country for their own dirt piles. #Ukraine#corruption#demining#Kherson#war 📱American Оbserver - Stay up to date on all important events 🇺🇸

Третя Сила

@The3rdForceUA · Post #30280 · 11.11.2025 г., 18:12

"Освободитель” із Башкирії зізнається, як вони брали Херсон — розстріли, приниження, страх. Так виглядав “русскій мір” на українській землі. 11 листопада — день, коли Херсон знову став вільним. 🇺🇦Ми пам’ятаємо, хто прийшов убивати, і хто вистояв. — Едгар Миротворець | @edgarmirotvorec Повне відео ТУТ : https://youtu.be/lUI9c2TNThc #Херсон#ХерсонЦеУкраїна#11листопада#Окупанти#ВоєнніЗлочиниРФ#EdgarMirotvorec#ЕдгарМиротворець#ПравдаПроВійну#Війна#Ukraine#StopRussia#Kherson#KhersonLiberation#RussianArmy#WarCrimes#FreeUkraine

DruschbaFM - English

@druschbaFm_en · Post #51795 · 09.03.2025 г., 08:12

⚡️🇷🇺🇺🇦⚡️ Two Majors #Summary Overview for the Morning of 9 March 2025; 06:55 (GMT+3)⚡️ ⚔️ Key Frontline Developments 🔹 The Russian Army has launched a large-scale operation to liberate #Sudzha in the #Kursk region. Using a bold manoeuvre along a gas pipeline, troops breached AFU defences, encircled #Martynovka, raised the flag in #CherkasskoyePorechnoye, and engaged in battle within #Sudzha itself, where the enemy is retreating. The same pipeline once carried gas to #Europe via #Ukraine, with Kiev collecting transit fees even during the war. 🔹 The Offensive followed extensive preparations - bridges, communication hubs, and UAV relay stations were targeted. While heavy fighting continues, AFU defences have been pushed back significantly. 🌍 International Situation: War vs. Peace 🔸 Trump’s Efforts to limit aid to #Ukraine are largely symbolic. Kiev has stockpiles for months. Meanwhile, #Europe ignores #US intelligence-sharing bans and prepares for a larger conflict. The #EU plans to allocate $800 billion to Ukraine, the Bundeswehr and Polish military are expanding, and Macron has even suggested nuclear escalation. 🔸 British and French Interests: Due to #France and #Britain’s ambitions in the #Odessa region, Russian nightly strikes with Geran drones and missiles continue. London is increasing its control over AFU operations, boosting Ukraine’s naval capabilities and promoting its military leadership. ⚔️ Frontline Pressure and Tactical Shifts 🔹 Oskol River: A new foothold is being secured south of #Kupyansk. 🔹#Seversk Sector: Fighting has moved west of #Belogorovka. 🔹#ChasovYar: Russian forces advance in the Western district. 🔹#Pokrovsk: Ukrainian reserves have been deployed, with villages changing hands multiple times. 🔹#VelikayaNovosyolka: Russian control expands westward. 🔹#Zaporozhye Front: Clashes persist over #Pyatikhatki and approaches to #Shcherbaki. 🔹#Kherson Direction: Ukrainian forces attempted a landing near 'Antonovsky Bridge' but were eliminated. 🛡 Drone Attacks and Air Defence 🔹 Ukrainian Drones continue targeting Russian oil refineries. Some regions have strengthened air defences, but enemy drones still reach critical infrastructure due to organisational failures. No one takes responsibility for destroyed fuel depots or damaged equipment. 💥 Ukrainian Strikes on Russian Territory 🔹 The AFU continues targeted terror attacks on civilians in Russian border regions and the #DPR. This raises doubts about any 'peace agreements' and highlights the failure of past international monitoring efforts, such as the OSCE mission in #Donbass. 🕊 Reality of 'Peace Talks' 🔹 In Reality, war preparations are escalating. Even without additional European supplies, Ukraine can sustain combat for months. Mobilisation in Ukraine remains active, ensuring AFU combat readiness. The enemy has adapted to manpower shortages and semi-encirclements, fortifying new defensive lines while slowing Russian advances. 🔹 The only decisive Factor would be a complete halt to all Western military funding and intelligence support. However, the military-industrial complex and Western elites are deeply invested in prolonging the war. 🇷🇺 Russia: The Key to Lasting Peace 📌 The Russian Army remains the only force shaping conditions for long-term stability and securing a strong position for Russian policymakers on the global stage. 💬Welcome to Military Chat; 🇬🇧Battle Maps 📱 Join GLOBAL DEPTH to boost your TG Feed GLOBAL DEPTH from #HK This channel aims to unite interested individuals from around the world in an attempt to connect the dots. Subscriber participation is always welcome here and in the channel's Chat Group.

DruschbaFM - English

@druschbaFm_en · Post #52695 · 30.03.2025 г., 07:55

⚡️ 🇷🇺 🇺🇦📆 Weekly Ukraine War Roundup⚡️ 🕊 The Negotiation Process was repeatedly undermined by Ukraine, which not only targeted key Russian energy sites with UAVs but also destroyed the strategic 'Sudzha Gas Metering Station.' Reports suggest a British HIMARS crew, using the #US system and French satellite support, was involved, though the full extent of foreign involvement remains to be clarified. Trump's team has hinted that ending the war in 100 Days is unlikely, while #US military aid and intelligence sharing with Kiev continue. 🇷🇺#Russia’s Battlefield Advances remain the main negotiating factor, given economic size and limited diplomatic progress. European bureaucrats, having sacrificed national interests for Washington, now fuel war hysteria to justify arms production. Military preparations against #Russia are evident, with discussions about restoring 'Nord Stream' taking on strategic importance. #Germany has postponed its green transition from 2030 to 2038, while Rheinmetall scrambles to increase arms output. ⚔️Frontline Situation 🔴 In #Sumy Region, there is progress, with Russian forces capturing #Veselovka, another village near #Zhuravka. 🔴 In #Kursk Region, heavy fighting continues. Russian forces have liberated new areas, reaching the 'Sudzha Border Checkpoint.' The AFU retains only two small pockets, offering no real bargaining power. 🔴 In #Belgorod Region, in the border sector, Russian troops fight mobile defensive battles near #Popovka and #Demidovka, areas that have changed hands multiple times last week. The AFU continues to shell the region, inflicting civilian casualties. Despite losing dozens of vehicles, Ukrainian forces retain offensive potential in the #KrasnayaYaruga sector. Additional enemy troop concentrations towards #Belgorod could force 'Group of Troops North' to redeploy units for defence rather than using them in the #Sumy offensive. 🔴 On the #Svatovo Front, further east, Russian forces secured #Krasnoye1st in #Kupyansk sector, expanding their Oskol River bridgehead and threatening the enemy’s flank. 🔴 In other Front Sections, #Russia maintains strategic initiative. South of #Toretsk, Russian forces stretch AFU defences by attacking the 'pocket' on the right #Pokrovsk flank, taking #Aleksandropol and #Panteleymonovka. Battles continue for #Tarasovka. Heavy fighting persists near #Pokrovsk, where the AFU is counterattacking. On the left flank, the RFAF advanced towards #Kotlyarovka, reigniting discussions about reaching the #Dnepropetrovsk region. In #Komar Direction (north of #VelikayaNovosyolka), Russian troops push forward daily. 🔴 In #Zaporozhye Direction, Russian airborne units advance through #Stepovoye and #MalyeShcherbaki towards #Shcherbaki and #Orekhov. In #Kherson, the AFU attempts to create pressure points on the Russian-held bank, particularly near the railway bridge. Ukrainian sabotage groups in the Black Sea continue drone attacks on #Crimea. 🇺🇦The AFU remains capable of organised defence and counterattacks, tying down Russian forces in #Belgorod region. #NATO flights to #Poland confirm that Western aid, though reduced, still reaches the front. Forced conscription enables Kiev, fully reliant on #EU support, to replenish losses and plan new operations. ❗️Talk of an imminent AFU Collapse or successful peace initiatives is premature and damages the RFAF morale. The ongoing need for mobilised troops, now officially acknowledged, shows Russia cannot yet replace them with contract volunteers. Continued reliance on volunteer support also highlights logistical gaps. As #Europe edges closer to war preparations, the need for military reform becomes increasingly urgent. 📌 Notes: A Russian view; in supplement: West of #Toretsk, the AFU advanced in #Shcherbinovka. The RFAF reentered #Uspenovka (#Pokrovsk, left flank). 🗺 Map Tsarov;📋Source: 2M 🕰As of 30 Mar 2025; 07:03 GMT+3 📃29 Mar;#sum 📱 Join GLOBAL DEPTH to boost your TG Feed 💬Join Military Chat for Comments & Discussions 🇺🇦On Ukraine Observer you will find your daily independent Ukraine War Battle Update

DruschbaFM - English

@druschbaFm_en · Post #52910 · 06.04.2025 г., 08:02

⚡️ 🇷🇺 🇺🇦📆 Weekly Ukraine War Roundup⚡️ 🗣 The Past Week saw continued global turbulence. The spotlight was on Trump’s introduction of sweeping protective tariffs, signalling a move towards super-protectionism. The era of globalism and idealistic notions of 'international division of labour' is fading, , giving way to intensifying trade wars. Washington aims to bring real industrial production back to the #US, streamline spending, and balance trade, particularly with #China. #EU officials voiced concern, but antiwar protests in cities like #Rome, with slogans like 'We need hospitals, not missiles,' better reflect public sentiment. Meanwhile, #Europe’s elite exploits the 'War with Russia' narrative to serve arms lobbies and divert funds from social programmes. The #US also saw protests, mainly driven by the societal split after years of liberal-fascist propaganda from Biden’s camp and its allies. 🇷🇺 In Diplomacy, the arrival of Dmitriev, envoy of the Supreme, in the #US was notable. His talks focused less on peace in #Ukraine and more on the economic benefits of working with us, compared to the costly, unconditional arms deliveries to Kiev. 🔸 Such Meetings are often spun at home as signs of a 'coming end to the war' which is misleading. Unquestioning belief in this narrative has weakened logistical support for the front and sparked rumours among troops about an imminent ceasefire. This undermines morale among fighters and officers, who see it as premature compromise. ⚔️ On the Fronts, while the RFAF maintain strategic initiative, the AFU is carrying out a defensive operation to slow our advance along the Line of Contact. 🔴 In the Invasion Zone, the AFU still hold #Kursk border settlements, while the RFAF fight deeper into #Sumy region. Battles continue at #Popovka and #Demidovka in #Belgorod region, with the AFU reinforcing across the border. Signals indicate they retain reserves for further provocations. In #Bryansk region, officials finally acknowledged daily AFU shelling of civilians, though some incidents go unreported, frustrating locals and raising doubts about regional control. 🔴 On the #Svatovo Front, north of #Kupyansk, the RFAF expand their bridgehead on the Oskol’s right bank. Southward, intense fighting continues. On the #Liman axis, control expands from #Katerinovka to #Ivanovka. 🔴 At #ChasovYar, fighting with little movement. Near #Konstantinovka, we have engaged in battles at #Andreyevka. After weeks of combat in #Toretsk, we shifted southward, taking #Panteleymonovka and #Aleksandropol, fierce clashes rage in #Tarasovka and at #ZelenoyePole. 🔴 Around #Pokrovsk, momentum has shifted, Russian troops now advancing in #Lysovka. 🔴 In #Komar Direction, clashes continue south of #Razliv, at #Vesyoloye and #VolnoyePole. 🔴 On the #Zaporozhye Front, Russian forces took #Lobkovoye after gains at #Shcherbaki and #Stepovoye. Reportedly renewed action at #Kamenskoye. In #Kherson region, mutual strikes, and the RF Aerospace Forces increased FAB use this week. 💥 A recent AFU Strike on a key fibre-optic plant highlighted weaknesses in our air defences. Command inertia, underuse of anti drone tools, poor coordination, and lack of accountability among senior officers still lead to avoidable damage, despite most UAVs being downed, often over towns. Low pay and unfair compensation remain concerns among air defence crews. ❇️ In Summary, any 'societal relaxation' amid continued heavy fighting and Kiev’s consistent disregard for agreements, while the #US keeps supplying arms and intelligence to the AFU, looks naive. Mocking the AFU or potential adversaries has already cost Russia dearly, leading to the war now entering its 4th year. 📌 Notes: A Russian view; in supplement: In #Toretsk itself, the RFAF also advanced. In #Basovka the battle has shiftet to its southern part (Sumy).🗺👆 🗺 Map CC;📋Source: 2M 🕰As of 6 Apr 2025; 07:22 GMT+3 📃5 Apr;#sum 📱 Join GLOBAL DEPTH to boost your TG Feed 💬Join Military Chat for Comments & Discussions 🇺🇦On Ukraine Observer you will find your daily independent Ukraine War Battle Update

ПретходнаСтраница 1 од 3Следна