@xinwenchigua8 · Post #66692 · 10.05.2026 г., 11:39
#闯红灯 看到有车过来你还跑! #Running a red light! You saw a car coming and you still ran!
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
Пребарај: #running
@xinwenchigua8 · Post #66692 · 10.05.2026 г., 11:39
#闯红灯 看到有车过来你还跑! #Running a red light! You saw a car coming and you still ran!
@markhemist · Post #100 · 09.10.2024 г., 10:58
🔤🔤🔤🔤🔤🔤🔤 ✅Scientists from Denmark have developed a pill that replaces intense training. Researchers from a Danish university claim that the molecule, called LaKe, has the same effect on the body as a 10 km run. 💯The drug is currently being tested on mice, but chemists are convinced that it will soon be possible to conduct tests on people. Dr. Thomas Poulsen, responsible for the invention, believes that their development will help people with ailments such as heart problems live better. All you need to do is pop LaKe while continuing to chill on the couch. A magic pill for remote workers, finally. #Running#Denmark MARKHEMIST
@bbvonline · Post #1005 · 17.04.2026 г., 12:43
Немного утреннего бразильского солнца вам! Пробежаться по пляжу Копакабана в 6 утра бесценно, даже если у вас разорван мениск. На связи, ББВ #running #copacabana
Hashtags
@milideaspararegalar · Post #6413 · 03.09.2023 г., 16:56
Brazaletes LED reflectantes para hacer deporte #BrazaleteReflectante#Deporte#Running https://www.milideaspararegalar.es/producto/brazaletes-led-reflectantes-para-hacer-deporte/ 💻www.milideaspararegalar.es
@milideaspararegalar · Post #6128 · 19.08.2022 г., 16:56
Brazaletes LED reflectantes para hacer deporte #BrazaleteReflectante#Deporte#Running https://www.milideaspararegalar.es/producto/brazaletes-led-reflectantes-para-hacer-deporte/ 💻www.milideaspararegalar.es
@milideaspararegalar · Post #5614 · 31.08.2021 г., 15:57
Brazaletes LED reflectantes para hacer deporte #BrazaleteReflectante#Deporte#Running https://www.milideaspararegalar.es/producto/brazaletes-led-reflectantes-para-hacer-deporte/ 💻www.milideaspararegalar.es
@teasticker · Post #9304 · 22.02.2022 г., 08:15
#HeavensLamby#scream#running#animated
@testflightynoti · Post #38113 · 12.05.2026 г., 18:48
#ROLO#RUNNING#ASSISTANT Join the ROLO - RUNNING ASSISTANT beta on ✈️#TestFlight 🔗 Link: https://testflight.apple.com/join/SnY1Jbzr Shared by Dimitri
@TestFlightX · Post #34828 · 10.12.2024 г., 02:09
#TRAINASONE#AI#RUNNING#PLANS https://testflight.apple.com/join/lJ1z2chB
Hashtags
@borkena · Post #5339 · 24.11.2025 г., 03:35
Sofi Malt Great Ethiopian Run International 2025 10km. Read more. https://borkena.com/2025/11/23/ethiopia-sofi-malt-great-ethiopian-run-international-2025-10km/#Ethiopia#News#GreatEthiopianRun#SofiMalt#running
@ChollazoExpres · Post #5639 · 08.01.2026 г., 18:30
💥Zapatillas Under Armour Ua Charged Assert 10 Corre con estilo y comodidad este invierno ✅OFERTA: 37.97€ ❌ Antes: 75.0€ 💰Ahorras un 49%🔥 Diseño resistente al frío, suela con amortiguación y ajuste perfecto 👉 Renueva tus zapatillas ahora #underarmour#zapatillasdecorrer#rebajas#deporte#running#ofertas#viral 🛰️Oferta publicada en Deporte y Outdoor
@milideaspararegalar · Post #6265 · 31.12.2022 г., 17:57
Braga para el cuello de calavera, un toque macabro y divertido a partes iguales #Deporte#Ciclismo#Running#ParaElFrío https://www.milideaspararegalar.es/producto/braga-cuello-calavera/ 💻www.milideaspararegalar.es