Index of Max/Min in 1 Line 🔥 in python | PyQuickies #36
Автор: Web & Beyond
Загружено: 2025-10-02
Просмотров: 911
Описание:
Need the index of the largest or smallest number? 😅
Python does it in 1 line with index()!
nums = [10, 25, 7, 42, 18]
print(nums.index(max(nums))) # 3
print(nums.index(min(nums))) # 2
⚡ Clean, short, and super useful.
❤️ Give a like and comment your views.
It helps us motivate 🙌
🌐 Need hosting?
Get fast & affordable hosting from Hostinger → https://shorturl.at/7Ej1K
💰 Use this link to get 20% EXTRA discount 🎉
✨ Support the channel
☕ Buy me a coffee → https://buymeacoffee.com/webnbeyond
🇮🇳 For Indian viewers → UPI: wnb26@ptyes
(Helps me create more free content 🙌)
📦 Developer Essentials:
👓 Protect your eyes → https://amzn.to/4mHta4I
💻 Keep your laptop cool → https://amzn.to/45obqpm
📝 Quick reminder tool → https://amzn.to/3UzgukA
📚 Full list of books & gear I recommend → https://rebrand.ly/9yiqge6
Disclaimer: These links are affiliate links—I may earn a small commission at no extra cost to you.
#python #pythonprogramming #pythonforbeginners #pythonquickies #webdevelopment #coding #pyquickies
Повторяем попытку...
Доступные форматы для скачивания:
Скачать видео
-
Информация по загрузке: