@QuietWorld · Post #7430 · 20.06.2020 г., 02:10
#collection@quietworld🍃 https://t.me/quietworld/6639
Hashtags
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
Пребарај: #collection
@QuietWorld · Post #7430 · 20.06.2020 г., 02:10
#collection@quietworld🍃 https://t.me/quietworld/6639
Hashtags
@QuietWorld · Post #6647 · 06.10.2019 г., 08:46
#collection
Hashtags
@StickersChannel · Post #743 · 02.02.2016 г., 09:59
❎ Waddles Collection ❎ https://telegram.me/addstickers/Waddles_Collection_By_Osmer #Waddles#Collection#OsmerOmar ↘️more Stickers at S4T.tv
Hashtags
@voir_yeux · Post #11551 · 31.01.2026 г., 08:51
🇷🇺 À Moscou s’est achevée la Semaine internationale de la mode atomique. Pendant une semaine, 60 finalistes du projet Territoire du succès: Mode 2025, issus des villes atomiques de Russie et des pays partenaires, ont suivi un cours intensif de formation. Le point culminant de la Semaine de la mode a été le défilé de la collection Le siècle de la mode russe. Photo: Sergueï Sevostianov/TASS #mode#finalistes#collection
Hashtags
@mdcuzbekistan · Post #50 · 26.06.2021 г., 05:52
List Qishloqdan kelganlar list nimaligini uncha tushunmaydi, o'zi list ham shu qo'yxonaga o'xshagan narsa (Xojiboy Tojiboyev) 😂 List - elementlarni va obyektlarni saqlashga moslashgan to'plam. Bu to'plamga List deb nom berilishiga sabab, ro'yxatlar bilan qulay ishlash mumkin (tarjimasidan bilib olsa bo'ladi). Ro'yxatda nima qilishimiz mumkin, elementlarni ixtiyoriy joyga qo'shish yoki ixtiyoriy joyidan o'chirib tashlash va tartiblash (sort) funksiyasi borligi bilan boshqa to'plamlardan ajralib turadi. 👉Batafsil 👨🏫 Mentor: Tolibjonov Abdulloh #csharp#collection#list#basic .NET Uzbekistan Community ______ Telegram | Instagram | Youtube
Hashtags
@wall_amv · Post #8721 · 19.04.2024 г., 21:02
#Anime #Orginal #Fan_Art #Televisions #Collection #Album #Wallpaper #AnimWorld @Wall_Amv
@wall_amv · Post #8711 · 19.04.2024 г., 21:02
#Anime #Orginal #Fan_Art #Televisions #Collection #Album #Wallpaper #AnimWorld @Wall_Amv
@botsgram_cu · Post #3353 · 02.01.2021 г., 02:17
@GuideRobot Qué puede hacer este bot? Este bot te ofrece un catálogo de los mejores canales de telegram Idioma: Inglés (visto en @BotsGram_cu) #manybot, #collection, #create, #subscription, #telegram
@libreware · Post #918 · 06.04.2021 г., 13:39
TrackerControl TrackerControl allows users to monitor and control the widespread, ongoing, hidden data collection in mobile apps about user behaviour (‘tracking’). To detect tracking, TrackerControl combines the power of the Disconnect blocklist, used by Firefox, and our in-house blocklist is used, created from analysing ~2 000 000 apps! Additionally, TrackerControl supports custom blocklists. 💡 This approach 👉🏼 reveals the companies behind tracking, 👉🏼 allows to block tracking selectively, and 👉🏼 exposes the purposes of tracking, such as analytics or advertising. The app also aims to educate about your rights under Data Protection Law, such the EU General Data Protection Regulation (GDPR). Under the hood, TrackerControl uses Android’s VPN functionality, to analyse apps’ network communications locally on the Android device. This is accomplished through a local VPN server, to enable network traffic analysis by TrackerControl. 💡 No root is required, other VPNs or Private DNS are not supported. No external VPN server is used, to keep your data safe! TrackerControl even protects you against DNS cloaking, a popular technique to hide trackers in websites and apps. TrackerControl will always be free and open source, being a research project. https://trackercontrol.org/ https://github.com/OxfordHCC/tracker-control-android/releases/latest/download/TrackerControl-githubRelease-latest.apk #TrackerControl#data#collection#android#apps#opensource 📡@nogoolag
@botsgram_cu · Post #3186 · 26.11.2020 г., 23:25
@FavoriteStickersBot Qué puede hacer este bot? Con este bot puedes coleccionar tus pegatinas favoritas en un solo juego de pegatinas! Idioma: Inglés (visto en @BotsGram.cu) #sticker, #pack, #collection, #favorite, #create, #set
@botsgram_cu · Post #3185 · 26.11.2020 г., 23:25
@StickersDownloaderBot Qué puede hacer este bot? Con este bot puedes coleccionar y descargar pegatinas Exporta el paquete de pegatinas de Telegram en un archivo zip. Idioma: Inglés (visto en @BotsGram.cu) #sticker, #pack, #collection, #favorite, #create, #set
@AloneSnowflake · Post #200 · 25.11.2023 г., 00:50
ᴡʜɪᴛᴇ ᴛʜᴇᴍᴇ ᴄᴏʟʟᴇᴄᴛɪᴏɴ .★. ᴡʜɪᴛᴇ ᴀɴᴅ ʙʟᴀᴄᴋ ᴡʜɪᴛᴇ ᴀɴᴅ ᴘɪɴᴋ ᴡʜɪᴛᴇ ᴀɴᴅ ᴘᴜʀᴘʟᴇ ᴡʜɪᴛᴇ ᴀɴᴅ ᴅᴀʀᴋ ʙʟᴜᴇ ᴡʜɪᴛᴇ ᴀɴᴅ ʟɪɢʜᴛ ʙʟᴜᴇ ᴡʜɪᴛᴇ ᴀɴᴅ ɢʀᴇᴇɴ ᴡʜɪᴛᴇ ᴀɴᴅ ʏᴇʟʟᴏᴡ ᴡʜɪᴛᴇ ᴀɴᴅ ᴏʀᴀɴɢᴇ ᴡʜɪᴛᴇ ᴀɴᴅ ʀᴇᴅ .★. ᴀᴘᴘʟʏ ᴛʜᴇᴍᴇ ᴛɢx .★. ᴊᴏɪɴ ᴄʜᴀɴɴᴇʟ #Light#White#Black#Pink#Purple#Blue#Green#Yellow#Orange#Red#Collection#Text