Python Tutorial for Beginners 7: Loops and Iterations - For/While Loops
Vložit
- čas přidán 5. 07. 2024
- In this Python Beginner Tutorial, we will begin learning about Loops and Iterations. Specifically, we will be looking at the for/while loops. We will learn about iteration and also how to break out of the loops using the break and continue keywords. Let's get started.
The code from this video can be found at:
github.com/CoreyMSchafer/code...
Watch the full Python Beginner Series here:
• Python Programming Beg...
✅ Support My Channel Through Patreon:
/ coreyms
✅ Become a Channel Member:
/ @coreyms
✅ One-Time Contribution Through PayPal:
goo.gl/649HFY
✅ Cryptocurrency Donations:
Bitcoin Wallet - 3MPH8oY2EAgbLVy7RBMinwcBntggi7qeG3
Ethereum Wallet - 0x151649418616068fB46C3598083817101d3bCD33
Litecoin Wallet - MPvEBY5fxGkmPQgocfJbxP6EmTo5UUXMot
✅ Corey's Public Amazon Wishlist
a.co/inIyro1
✅ Equipment I Use and Books I Recommend:
www.amazon.com/shop/coreyschafer
▶️ You Can Find Me On:
My Website - coreyms.com/
My Second Channel - / coreymschafer
Facebook - / coreymschafer
Twitter - / coreymschafer
Instagram - / coreymschafer
#Python
I've been studying python coding for a while (on and off) and until a couple of days ago I had never heard of you. Like I said, I've looked a lot of material throughout various websites when it comes to Python learning so I'm surprised I had never known your CZcams channel. I came across your name while going through my Reddit feed and someone had asked a question who is the best Python tutor and your name was on top of the list with an excessive amount of upvotes and after looking you up I can definitely see why that was the case. Your videos are short and to the point and explained in the most simplest of terms; making them easy to grasp and not leaving anyone dumbfounded. Thank you so much providing these videos as they're helping immensely.
I don’t skip ad that comes in your videos. I don’t know if you get paid if we don’t skip ads. That is the least I can do for now. I am definitely donating, once I get a job in my field. Thank you for this Corey. It is truly amazing!
donate now its your time bro
Ya bro donate
Corey I don't think I have come across a better Python training material than this. It is just too good and explains in detail about the concepts with good examples.
I've tried many tutorials explaining while and for loops on youtube. This guy is by far the best tutor explaining them very clearly.
Guy I was like you
I wonder, who the one hell has given the thumbs down for such a beautiful video on python learning!!
I guess who doesn't like python. :D from one big like.
Add me in the list.. Python is the most horrible language. C++ (or all other C-like languages) are far more better and conceptual
Maybe because he ran an infinite loop and told us that the way to stop an infinite loop on most operating systems (by the way, a majority of the operating systems in use today are Windows operating systems) is to press Ctrl + C, but in most Windows environments, Ctrl + C is used for copying objects. TL;DR: False information
Ryan Nordquist nope. Linux is far more better than that shitty windows. And world is moving towards it..
@Tech store, C++ is the most horrible(read complex) language. Google it.
Awesome job! I can tell you that as someone who has taken programming as part of my degree in college you do an amazing job at explaining things. Crystal clear. Thank you for this content and the hard work you put into this series. This is helping me immensely!
These are hands-down the best tutorials for python I have ever seen.
Keep doing the amazing work.
Your examples you provide are so much more helpful then the very basic "here is a for loop" explanation. You go one extra step to provide a more real world use, which is much more helpful for me. Thank you!
Hello Corey, a few days ago I was stuck trying to understand how to work with files from a python book I'm reading, so I decided to look for other resources, and that's how I found your video tutorials. I really like how you explain things, I see that you put an effort for us to understand the concepts and not just memorize stuff.
I appreciate you took the time to make this videos since they have been a great learning resource for me. Keep up the good work!
Saludos desde Mexico!
Glad to hear you found the videos useful!
Corey your tutorial vids are the most elegant and well-paced among all the vids that I have been trying to follow. Thanks a lot and keep up the great work :)
Finally a clear understanding of While Loop. Thank you Corey.
Wow! You are the first person I've came across on the internet who has explained this so well! Thank you Corey!!! I'm a math fanatic and I wanted to learn iterations and loops so badly for my own sake but apparently no one explained well enough how to make the infinite loop stop without pressing ctrl C, as they didn't know how to explain well enough.
Man, Thank you so much. Your videos are the only ones that explain it in such a detailed, yet approachable manner. I've learned more by watching your videos than any other resource out there.
Again. Thank you. If you ever have a bootcamp, let me know. lol
Best Python tutorials I've ever seen on CZcams. Organisation of material, clarity of presentation, pacing of instruction all 10/10. I do online tutoring myself, so I'm very conscious of these requirements.
You should try Telusko
Wow this was so simple. I have been reading articles, the textbooks, and attending lecture, but this was just, straightfoward. Wow. You have amazing teaching and explanation skills.
Hey Corey. You're absolutely amazing. A clear and slick way of understanding anything in your tutorials. It would be a great help if you give out various examples and explain them. Like the whole program itself involving all the elements from previous videos. Thanks a lot. You're educating thousands for free.
Honestly speaking (because I've struggled a lot) , there is no loop video that tops yours! You say just what needs to be said to grasp the general idea! Thanks man, you are the best! I will absolutely watch your content!
I dont get how i pay 9000 dollars a semester when i learn from CZcams for free.
Feel free to share with your classmates :)
@@coreyms do you know how to make a loop where it ask an user input production per day and increases 1 day in the question, for example ("Enter production at day 1) then each time it ask it changes to 2,3,4,5. Is this possible?
If you haven't found out yet, here's a possible solution. Make a file with "1" in it. Then make a python program that reads the file, uses the number in the file, and then when it is done it overwrites the file by making the number larger by adding the number one to it.
Its the piece of paper that is worth the $9000 ..... lol
I know right!!
love this guy. talks business, no unnecessary words. it really saves time
I tried to learn programming quite a few time and quit countless times... you are the one with whom i actually i made it as far as this video..been here since python tutorial for beginners 1 ...and plan to complete and rock like you do :) ....keep it up bro... great work ...much love
How’d it go
I'm happy for you, Han! : )
Update please
@@Justin-ky1cr Almost done with django, i wrote some silly programs for my friends business and they liked it...learning more and more as i go on
@@voke4553 Explanation is so easy, i actually learn concepts from here. Still i do have to visit old videos sometimes for refreshing my memory :)
I dint understand the loops clearly until i watch this video...Thank you so much sir..you are the best python teacher on You Tube :)
Your tutorials are amazing. Please make more of these tutorials. I am going through all of your videos.
Awesome tutorials. Tried learning with the "Learn Python the Hard way" book, but you explain concepts far more succinctly and clearly. Kudos
I have been struggling SO hard with loops in my Intro to Programming class and this helps so much. Thank you!
You can see mine too. The channel has Python crash course tutorials, with detailed code files downloadable. The channel has another playlist, R beginning course.
This is a great explanation of loops! Structured and clear. Thank you!
Thank you for making this video, i'm currently going through python in easy steps and was stuck on loops. You explain things so clearly :)
Thank you so much for this video, I have only recently began to study python and every has been a breeze until I got to loops. The teacher I had unfortunately didn't explain them well for me but I understand them way more thanks to this video. Much appreciated dude
This seems to help explain my confusion with loops. Loops are there to help us write out steps out in a simple manner rather than typing out consecutive steps.
With for loops, it’s for a definite number of times 1-5
But with while loops it can go on forever
Great tutorial! I’ve been having issues understanding loops, and your video gave a nice/short description of the basics of them. Thanks!
I'm taking a Python course right now for school & you definitely cleared up some confusion I had with for & while loops (I was over-thinking it too much smh). Thank you for breaking it down for myself & other CZcams subscribers!
As a Python novice, I am really really thankful of this video!!!! I was looking at the free linked in class and it was so confusing. You are lifesaving. Thank you so much!!!! Happy new year!!!
I actually got a clearer explanation from this video. Thanks for this. A million thumbs up from me.
Corey thank you, you are such a wonderful teacher. Comparing to others, you explain very easily.
No question brother. You explained so well. Love you!
Mr Schafer, you're actually doing a great job 👍💪. Totally simplified, impressive!
An excellent explanation of "for / while" loops within Python 3! Thanks.
Corey, thank you! This tutorial showed me how to fix a problem I was having with an assignment.
You are simply awesome. I can understand every bit of what you cover in your videos. Though I don't have any programming background, I thoroughly enjoy watching your videos. I'm confident now that I can learn python. Thanks!!
Thanks! your video tutorials is what i used as a video referrence to the book called 'lean python-learn just enough python..' really helpful.
Thank you Corey for your time and effort. Keep spreading the knowledge.
your videos are so unbelievably good. The things i dont unterstand in a whole schoolyear i learn in a couple days from your videos
I was afraid of programming languages but you came out as a Saviour.Thanks ,Sir.
what u doing now got job or something?
was about to ask lol
@@sukriti2415
really helpful, you did a great job explaining the different loops too, thank you!
Love the way that you explained this, I finally feel like this is starting to click. Thank you!
You are the one who made me pursue coding as a passion.
its lockdown day 10 : making use of time to learn Python again ..@Corey Schafer is only Hope after exploring more than dozen courses.
love your vids Corey. One minor suggestion would be to increase the font size in your IDLE. Would make it alot easier to view on different devices.
IDE you mean?
integrated development environment
Thanks! I had to go through quite a few other instructionals before I finally understood it with your video! Well done, congrats! Teaching code to newbies is not an easy task ;-)
finally I understood looping in python. u the man.
The best explanation of loops and iterations!
Thanks Corey joon!
Best Python tutorials out there, hands down!
dude you and your videos are pure gold
your videos are always the best. you are GREAT Corey
The way you teach is amazing.! Thank you so much for uploading these videos. Im subbing!
You are a Gem amongst mentors
Another awesome breakdown. Very simple and easy to follow
Really nice explanation on this concept of loops! Thank you!!
Good stuff, just got done with Pandas a few weeks back and now I am filling in some gaps. Thanks for this wonderful content
Fell very easy to understand and I will follow it.Thanks
Definitely helped my understanding. Thank you. This is much appreciated
Thank you! I had been stuck as my list was counting downwards.
A great tutorial, hope to see more video tutorials about different statements in python.
this is the best python learning channel on CZcams..
good job, clear and smoothy .. thank you in infinite loop
break
i really appreciate ur knowledge BRO!!! hats off for you.
Excellent tutorial about python, I like all your video very much. Will wait for your tutorial regarding python popular packages like NumPy, Pandas, Scipy. Appreciate your effort
While loops have always been confusing to me. Thank you for clearing this up!
Loving the series!
I never "like, comment, and subscribe" but I'm learning Python and I was hard stuck trying to figure out why my loops weren't working and turns out they key was the 'continue' command that I didn't know about. Thank you so much!
Hey, i really loved your videos very much it's very interesting and you teach in a very understandable way for anyone with non-computers background.
I would really love that you did videos of Machine learning in python as it will be useful for most people like me i'm a beginner in data analytics using R software and now i'm interested in learning python for data science and bit automation.
thanks for creating this video. reviewing for my comp sci midterm
Your videos are so easy to follow 👍
Great overview of Py loops!
I learnt new things..... Thank you for uploading these videos.....
so clear and brilliant explanation
Amazing Corey ! 👍
very useful videos great for my computer science revision :)
amazing to have such good content for free.
i guess i am gonna pass this semester with the help of your videos. Because all my courses like artificial intelligence and digital image processing need python and thank you for clearing my concepts.
You're very good teacher, thankyou so much.
that so F**ing easy now damn ive try do understend that for 2 days and here u come with a damn 11 min video and now i can explain it OMG i was so frusterated!!! ty so much man
your explanations are fantastic
Very helpful mate, great video!
Very very clear explanation, thanks sir.
for x in range (1,1000):
print(' LOVE THIS VIDEO')
if x==1000:
break
bruh
@@medinusa1 bruh it breaks by itself
@@medinusa1 Lmao, it'll break itsef
I like your style Corey :) many thanks
thank you so much!!this was extremely useful:)
even after these many years his videos are still intresting 🙌
your tutorials are the best!!
Best explanation . Thank you.
This channel deserves more subs
i really admire your explanation, you are great
Super! Thank you for sharing!
👍best video with clear and neat explaination
great explanations - thank you!
You have a clear English so I can understand it easily.
Best version of python for programmers and beginners for self study.
Guleid Muhuyadin and for college students
I don’t understand the material in my class but this helped me so much hahaha
All we need is a time and space complexity and this playlist would be complete!
Great explanation , thanks
You are Awesome Corey !!! Thanks a lot :D