@perspectiveix · Post #1577 · 01.10.2018 г., 18:00
🤣Launch of Windows 95 Nothing is more motivational than this #MondayMotivation - featuring Bill Gates, obviously! 😂 🚀@PerspectiveIX 💌Weekly Pulse: prs.pctvix.co/2wj5dt3
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
Пребарај: #mondaymotivation
@perspectiveix · Post #1577 · 01.10.2018 г., 18:00
🤣Launch of Windows 95 Nothing is more motivational than this #MondayMotivation - featuring Bill Gates, obviously! 😂 🚀@PerspectiveIX 💌Weekly Pulse: prs.pctvix.co/2wj5dt3
Hashtags
@perspectiveix · Post #1249 · 07.05.2018 г., 07:01
“The best time to plant a tree was 20 years ago. The second best time is now.” — Chinese Proverb #MondayMotivation 🚀@PerspectiveIX 📚https://prs.pctvix.co/2JXpl93
Hashtags
@perspectiveix · Post #1221 · 23.04.2018 г., 11:30
"The world is a dangerous place to live, not because of the people who are evil, but because of the people who don't do anything about it." —Albert Einstein #MondayMotivation 🚀@PerspectiveIX 📚https://prs.pctvix.co/2K7cuC3
Hashtags
@JIFAR1 · Post #152 · 14.04.2025 г., 12:12
Did you know Facebook Ads can reach over 2.11 billion people that’s more than a quarter of the world’s population Whether you’re a small business or a solo content creator, your ad has the potential to go global with just a few clicks. This week, don’t just scroll strategize. Start small, test your ideas, and learn as you go. #MondayMotivation
Hashtags
@ikhtiyorrakhman · Post #77 · 05.01.2026 г., 04:39
📚 Bugun o‘qigan kitobingiz ertangi qarorlaringizni belgilaydi. BMT Taraqqiyot Dasturining O‘zbekistondagi doimiy vakili o‘rinbosari Anas Fayad Qarman tavsiya qilgan ushbu kitoblar taraqqiyot, identitet va inson salohiyatiga boshqacha nigoh bilan qarashga undaydi. Ular davlatlar nega rivojlanadi yoki tanazzulga uchraydi, inson o‘zligini qanday anglaydi, sokin odamlar qanday kuchga ega ekanini ko‘rsatadi. Bugun bitta kitob tanlang. O‘zingizga sarmoya qiling. Chunki bilim eng kuchli kapitaldir. #MondayMotivation
Hashtags
@ikhtiyorrakhman · Post #16 · 16.07.2025 г., 10:35
📚 Haftani ilhom bilan boshlang! Kitoblar ruhimizni boyitadi, fikrlarimizni charxlaydi va yangi g‘oyalarga yo‘l ochadi. 🤝 BMT Taraqqiyot Dasturining O'zbekistondagi doimiy vakilasi Akiko Fujii o‘qishga arziydigan 5 ta kitobni tavsiya qiladi. Bu asarlar turli mavzularni yoritadi – inson taraqqiyotidan tortib, jamiyatdagi tenglik, bag‘rikenglik va adolatgacha. 👇 Ushbu 5 ta tavsiya bilan tanishing va siz ham o‘z kutubxonangizga yangi sahifalar qo‘shing! #MondayMotivation
Hashtags
@MB4K_Tech_Telegram · Post #2943 · 11.03.2024 г., 08:47
Good morning! 🌞 Wishing you an incredible start to the week with this stunning #wallpaper. May it add a touch of inspiration to your day! ☺️#MondayMotivation
Hashtags
@perspectiveix · Post #1282 · 21.05.2018 г., 11:00
📰#iXDailyBrief STAT ⚡️ 40.2% of UK 18-25 year olds said that the posts they see on #SocialMedia have influenced their career decisions. (Source: CV-Library) INSIGHT 🌳 Eventually All the Dots Will Connect: An Organic Growth Strategy: prs.pctvix.co/2LjuVo0 OTHER NEWS 👑 The best social media reactions to the royal wedding: prs.pctvix.co/2Ld8yR3 🗞 News publishers recoil at Facebook’s new political advertising rules: prs.pctvix.co/2LkglfU ⚖️ The UK wants to police social media with new ‘online safety’ laws: t.me/iXNews/25674 🤝 Progressive advocacy groups call on the FTC to “make Facebook safe for democracy”: t.me/iXNews/25668 — "It always seems impossible until it's done." ― Nelson Mandela #MondayMotivation Ben, @iXNews
@Diplomatika · Post #346 · 24.05.2021 г., 06:29
#MondayMotivation#Inspiration 👉@Diplomatika
Hashtags
@Diplomatika · Post #345 · 24.05.2021 г., 06:28
#MondayMotivation#Inspiration 👉@Diplomatika
Hashtags
@Diplomatika · Post #331 · 17.05.2021 г., 06:04
#MondayMotivation#Inspiration 👉@Diplomatika
Hashtags
@Diplomatika · Post #330 · 17.05.2021 г., 06:04
#MondayMotivation#Inspiration 👉@Diplomatika
Hashtags