Title | : | List Comprehension - BEST Python feature !!! Fast and Efficient |
Duration | : | 14:51 |
Viewed | : | 188,448 |
Published | : | 01-07-2022 |
Source | : | Youtube |
In this tutorial, we will learn all about list comprehensions and how they can make our Python journey much easier and much more efficient!! 🤓🤓🤓 List comprehensions provide a shorter and faster alternative to "for" loops (especially when combined with conditional statements as well as append commands). And best of all - it takes only 1 LINE OF CODE! 😱 This video offers 3 separate coding exercises, various examples and colorful illustrations of the concepts involved. Please feel free to use my code and artwork, you can find it in the link below: ⭐⭐ clone my code: ⭐⭐ ** Sorry code is unavailable, RIP Wayscript 😭😭😭** And on a festive note... 🍁HAPPY CANADA DAY!!!🍁 to all my fellow Canadians! (and other Earth dwellers who celebrate 😉) Sending you lots of love from beautiful British Columbia! 💗💗💗 ⏰ time stamps ⏰ ____________________ 00:00 - intro 00:17 - what is a list comprehension? 01:22 - for loop vs list comprehension 02:40 - coding example 06:07 - conditional list comprehension 06:27 - coding example 2 09:02 - list comprehension on strings 09:29 - coding example 3 12:09 - else if list comprehension 13:50 - coming soon: dictionary comprehension 14:12 - thanks for watching! 🐍🐍 related tutorials of mine 🐍🐍 _____________________________________ - For Loops: https://youtu.be/dHANJ4l6fwA ➡️➡️ starter code ⬅️⬅️ __________________________ fruits = ["apples", "bananas", "strawberries"] for fruit in fruits: print(fruit) 💳💳 credits 💳💳 _______________________ - Beautiful Icons are by: https://www.flaticon.com/ - Beautiful Like/Share/Subscribe video graphics by: https://mixkit.co/ 🤝 connect with me 🤝 _______________________ - Github: https://github.com/MariyaSha - Discord: https://discord.gg/wgTTmsWmXA - LinkedIn: https://www.linkedin.com/in/mariyasha888/ - Twitter: https://twitter.com/MariyaSha888 - Blog: https://pythonsimplified.ca
![]() |
Do you Need a Tutor or Mentor for Programming? 56:56 - 18,205 |
![]() |
Dictionary Comprehension - Create Complex Data ... 21:58 - 87,388 |
![]() |
10 Python Comprehensions You SHOULD Be Using 21:35 - 124,997 |
![]() |
Python List Comprehensions Made Easy!! 11:50 - 14,563 |
![]() |
OOP Class Inheritance and Private Class Members... 16:12 - 120,415 |
![]() |
11 Tips And Tricks To Write Better Python Code 11:00 - 604,313 |
![]() |
5 Good Python Habits 17:35 - 410,042 |
![]() |
Ultimate Guide to NumPy Arrays - VERY DETAILED ... 24:23 - 114,895 |