I cannot recomment Mosh's tutorials enough. Easy to follow, helpful and friendly style.
@henryalohfabian6686 Жыл бұрын
What is true and false
@henryalohfabian6686 Жыл бұрын
And why those he keep using it
@Cheesecake99YearsAgo3 ай бұрын
@@henryalohfabian6686 it is the Boolean logic It only has 2 results True and False
@the_seahawk224 жыл бұрын
I feel like reading the actual code or trying to determine what to type is why for loops are so fucking difficult to understand. Most of the time I am staring at other people’s code just overwhelmed
@murder89283 жыл бұрын
dude exactly, i have to write shit down
@OmSaiSwarupSetty3 жыл бұрын
Exactly the same feeling of mine too
@alyanna12603 жыл бұрын
ahh same same:((
@Asterics.3 жыл бұрын
same here man, logic is so hard to mix with any other data type
@aliasad13925 жыл бұрын
I am a new learner. And for some reason i feel it complicated dealing with loops. But i am determined. Hope so will understand it soon. Mosh you are a great teacher. God bless you.
@KidsLearnHTML4 жыл бұрын
Hi, I'm a high school teacher -and I COMPLETELY agree. It's like he's adding things that can distract from the learning process. For example using range instead of a regular list of let's say ["cow", "pig", " duck", "hen"] or ["baseball", "football", "swimming", "judo"]. It's kinda like a teacher using 2 or 3 terms a kid doesn't understand -to explain the FIRST term that the kid doesn't understand.
@mohammedalzamil71914 жыл бұрын
its been 8months did u get anywhere with coding?
@aliasad13924 жыл бұрын
@@mohammedalzamil7191 nah mate. Unfortunately i couldn't concentrate. Had to start my job to had less time for coding. I am sad
@mohammedalzamil71914 жыл бұрын
@@aliasad1392 man start again I started about 3 days ago and the thrill of running the program and it actually works is invaluable, look up the 4hr course on python it'll give u a good start
@swallowedinthesea114 жыл бұрын
Loops are one of the most riotously difficult topics for beginners in all languages, not just Python. I found it confusing when I first began. You just have to keep practicing. 06202020
@invinciblenoman3 жыл бұрын
I believe self-learning of programming becomes easier if you start implementing your latest learned codes in small programs. such as Mosh just made in exercise. try to find small exercises for 'for loops, nested loops, with if statements. it will increase your learning pace and keep you motivated.
@brianligat2038 Жыл бұрын
I split mine into different modules to experiment with particular topics. Easy to add to without a single module getting too large and messy. My main just has a menu (2 dictionaries of options and functions). I could then add other bits like a TicTacToe and Minesweeper game.
@syedmohammedakberhussaini56202 жыл бұрын
Dude, You made my Basics Very Strong print("Thank You Mosh")
@Ushq_QgA Жыл бұрын
super gədə
@harshalnath48532 жыл бұрын
first I am gonna take break in the middle of this video while learning and comment for this guy because this man deserve a huge respect because I roamed around so many videos but no one is so good as him love u man.
@amandal84044 жыл бұрын
this was exactly what I was looking for. it was a bit hard to follow written tutorials, so thanks for such a clear and concise one here!
@faridgulum12264 жыл бұрын
Thank you, Mosh. I learned the parts I lacked as a beginner. I also learnt how to add int to string in print function. :)
@Ryan789002 жыл бұрын
you should become a hacker for the United States NSA :))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))
@praanadhyarlagadda6413 Жыл бұрын
thanks so much, i have an exam.
@amilcarromero4656 Жыл бұрын
Lol, We all do
@Ali-xj8bs Жыл бұрын
Me too 😢
@ayaashraf596011 ай бұрын
same
@besnergreen8 ай бұрын
Haha samee.. gotta attend more classes
@archababu20149 күн бұрын
Good luck a year before
@sabamohammadi46174 жыл бұрын
دستت درد نکنه ماش بعد از چند تا ویدئویی که از for loops دیدم با ویدئوی شما بالاخره کار کردن باهاش رو یاد گرفتم
@stevena142520 күн бұрын
learn English then
@TifaS.F2 жыл бұрын
Hello there Mosh! This is my exercise code (12:37) My code: for i in range(2, 9, 2): print(i) print('We have 4 even numbers')
@t3rm1nat0r4 Жыл бұрын
Yeah this works really well in practice, and I don't see a situation where you can't use it but he specifically said not to add the third variable in the first parenthesis
@CIMiclette2 ай бұрын
Dude you're a hero, been struggling with loops (especially nested loops) in my fundamentals of computing course in school, you explained them much more clearly than my professor, thanks!
@smaransure22342 жыл бұрын
Thank you so much. I am pretty intermediate, but I never knew exactly how loops work. This video helped alot, so thank
@HelenNPerlas3 жыл бұрын
Thank you Mosh! I survived this topic. It helped a lot in my lessons on looping in Python.
@Ryan789002 жыл бұрын
Clap clap clap. Hooray for you, tutor me?
@tcpnetworks4 жыл бұрын
Sir - you are absolutely awesome to listen to :) Thank you for making this language so much fun.
@vatsal_gamit5 жыл бұрын
one the best videos on the internet for loops
@md.mahedihasanhridoy35715 жыл бұрын
Very nice presentation and you make coding just simple.
@emmanuelleallen11 ай бұрын
I've been learning Python for about a solid 2 weeks. Self-taught. And so I wouldn't say im an "Absoloute Beginner," but I'm not far off. And this tutorial was actually very difficult to follow in regards to the expectation. IT WAS informative though, and showed me a few things i havent looked at yet, though. I'd reccomend the following changes for videos like this in the future, if youre using the "absolute beginner" title. Any concept that isnt directly related to the for loop, should also be explained in a little bit more detail. You gave a challenge that required using knowledge that wasnt included in this video. These operands "%, ==, =, +=" These commands "if, else" Boolean results "True False" And a few other things. Realistically, this video is one of a series. And the title should be rightly have a series identifier on it. Like "Python for Absoloute begginer 8/20: For Loops" This would give the user the idea that there is likely information refrenced in this video using previous content. And builds off of *some* knowledge base. But meant for very intruductory users. Only sharing these things to help you and the viewers. Best of luck!
@Segun24-74 ай бұрын
Thanks a lot, I think I understand loops then I see it implemented and come back to watch tutorials. I guess I am stuck in a loop myself😪
@simphiwemtshali54522 жыл бұрын
I didn't understand my lecturer thanks to you... you the best
@alexgicheha57552 жыл бұрын
Hi Mosh! You're the best Tutor. I am looking forward to learning more from you. I want to learn python for data analysis, web development, and game development. I welcome all the challenges, but I am passionate about becoming a Pythonista. Whatever it takes, Mosh, as long as you're my tutor, I know I'll make a great programmer like you.😘🤩
@BIackBoomBox Жыл бұрын
Love the example you showed with the email. Made it easier to understand
@airmett8939 Жыл бұрын
for x in range(1, 10): if x%2==0: print(x)
@cornationboot8690 Жыл бұрын
count = 0 for x in range (2,10,2): print(x) count +=1 print("We have {count} even numbers")
@codewithelyanan65363 жыл бұрын
I finally understand about loops in python
@narutoxtreme1232 жыл бұрын
Just want to say thanks 🙏🏽. I have been using your videos along with my course work. Awesome 👏🏽
@christianwiah4526 Жыл бұрын
Thanks, Mosh - Your lectures are simplified and easy to follow.
@easydatascience2508 Жыл бұрын
See mine too. Easy to follow, most of the fundmental tutorials for Python and R. Source files can be found in the description of each video, by the way.
@TheTitanGrimm8 ай бұрын
Well you have the best explanation on for loops. Most other videos I couldn’t apply to my program. Thank you.
@uffeheden61003 жыл бұрын
Thanks! Exactly what I'm looking for where I'm in my learning curve. Great with the addons where most courses go. Cheers!
@Ryan789002 жыл бұрын
what the fuck do you mean by that?
@Ryan789002 жыл бұрын
😅😅😅
@Repeeeet Жыл бұрын
Wow!! This is awesome. I'm in a bootcamp and this was confusing. Thanks for posting this. I hipe you consider posting more recent tutorials.
@zahrabolghanabadi147811 ай бұрын
You are the best teacher in coding❤
@ZuhayerSarfaraz Жыл бұрын
bless you my man, bless you. Top tier crash courses out there
@LittleAres2 жыл бұрын
another way to solve the exercise could be this: for i in range(0,10,2): if i > 0: print(i) print('we have 4 even numbers') the result is still the same:D
@hogrider92496 ай бұрын
Thank you for these lesson, they help me a lot. I especially like the practices because they help me remember.
@monttyy48792 жыл бұрын
Your channel is helping me so much .. my teacher is so trash and doesn’t tell us shit and just expects us to understand from reading his examples
@siddiquebaloch7865 ай бұрын
for num in range(1,10): print(num*2) if num*2 ==8: if True: print('We have 4 even numbers') break
@tixer9786 Жыл бұрын
I think your way of doing the exercise can be simplified to this: for numbers in range(0, 10, 2,): print(numbers) if numbers == (8): print("There are 4 even numbers") #This is a much easier way of doing it
@faraic3 жыл бұрын
# great explaination i see why there is a million views.my code as below total = 0 for i in range(1,100): if i%3 == 0 or i%5==0 : total = total + i print(total)
@rohitsd7732 Жыл бұрын
for even in range(1,10): if even%2==0: print(even) print('we have 4 even numbers')
@sparkscomputerprogramming2 жыл бұрын
the best coding teacher in youtube
@Luka_WiFi5 жыл бұрын
for num in range(2, 10, 2): print(num)
@mr.transformer12999 ай бұрын
Good day sir, At 5:15- I tried Successful = True for number in range (3): print(“test”) print (“Successful”) if successful: break And I got the same result of; test Successful. Please what’s the implication of the difference in the positioning of the 4th and 5th line i.e The print (“successful”) and if successful? Thanks sir.
@yourpapa6641 Жыл бұрын
count = 0 for x in range (1,10): if x % 2 == 0: count += 1 print(x) print("We have " + str(count) + " even numbers")
@cornationboot8690 Жыл бұрын
hi bro why u use using concatenation, it will just merge them together instead try using , instead of +
@epicvoyager5938 Жыл бұрын
Thank you for the simple and quick instructions, you've been a great help!!
@pookie478 ай бұрын
This was so helpful me to me to understand.. and like.. comprehend. thank you
@accio55574 жыл бұрын
thanks a lot mosh i am glad i found this tutorial
@a.b.30303 жыл бұрын
Very good explained. Thank you.
@maryharrer26032 жыл бұрын
My Python book is only teaching me math. YOU are teaching me Python. Thank you.
@pallabidas59915 ай бұрын
Mosh, you are awsome ... I really learn through your videos.
@nabeelmirza63645 ай бұрын
which app does he use?
@jimgraham1404 Жыл бұрын
Thank you mosh. I know it’s simple and it’s perfect 😊
@muhammedmustafa76852 жыл бұрын
for i in range(lengte): # Create a list of columns for j in range(breedte): print("*", end="") print()
@jamonlewis646611 ай бұрын
Mosh you have the best tutorials on coding, but I wish, for the love of God someone would explain the syntax of the “for loop” so some sense could be made of why it’s written the way it is. I love how so much of Python correlates with the regular (English) language, but the “for loop” syntax is the most abstract & bizarrely written expression ever & NO ONE who I’ve come across that teaches python seems to think the format of the “for loop” syntax needs to be made since of for people learning python.
@mdbelalhossainsanto652311 ай бұрын
#Printing even number for num in range (2,10,2): print (num) print("we have 4 even numbers")
@VotiSam Жыл бұрын
even_number = 0 for i in range(1, 10): if i % 2 == 0: print (i) even_number += 1 print(" we have", even_number, "even numbers")
@druskii902 жыл бұрын
Thank you for explaining for loops very clearly, idk I've been struggling to understand them and this helped so much! Sub earned!
@ahmetunaldi7601Ай бұрын
Mosh is great for beginners.
@dasanb.k201020 күн бұрын
So many thanks for this contribution.
@nakshathraopillai6793 жыл бұрын
REALLY HELPFUL !!!!!!!!!!!!
@aliasad13925 жыл бұрын
If you are not a quick learner as i am Then try slowing video speed. I hope it will work. Slow mosh lolz
@muhammedmustafa76852 жыл бұрын
for number in range(0,101): if(number % 2 == 0): print(number)
@alaskachan59143 жыл бұрын
thank you very much for this tutorial.
@Kittay-12Ай бұрын
amazing tutorial but need one on while loops🔥🔥🔥
@lesyamaur77874 жыл бұрын
This was really helpful
@nerdifiedish13342 жыл бұрын
heres the answer for the exercise without looking: for x in range(1, 10): if x%2 == 0: print(x) print("we have 4 even numbers!")
@muhammedmustafa76852 жыл бұрын
Fizz = 3 Buzz = 5 FizzBuzz = Fizz * Buzz for a in range(51): if a % FizzBuzz == 0: print('FizzBuzz') elif a % Fizz == 0: print('Fizz') elif a % Buzz == 0: print('Buzz') else: print(a)
@phuongdungnguyenthi15742 жыл бұрын
Hi Mosh, thank you so much for your video! it's so helpful. I would like to ask that could I write the code like this: for x in range (2,10,2): Print (x)? When I run my code, it's still shown the similar result.
@ErrorXTech2 жыл бұрын
2, 3, 4, .... 9
@estherdouglas60962 жыл бұрын
2 4 6 8
@XzibitMe Жыл бұрын
Coding is fun and all but its a harsh reminder im gonna lose all my hair when watching mosh lol
@bishakhadeb18004 жыл бұрын
Thanks Sir. You're the best :)
@BettoRaite_2 жыл бұрын
iterables are the things that can launch the for loop and make the sequence of repetitions #I don't know if it's the right definition, but this is how I interpretered the meaning of iterables
@itchyfungus84812 жыл бұрын
If you're a beginner it's not you, it's the teachers. They teach how they were taught and so we live in this world. The issue is no one is breaking things down. They're all just diving in and repeating information that in truth they may not even know why to use a function in the order they used it. They just know it works. So the issue is, why to use a for loop and why to use range? why to combine these methods. Because once you understand why, then you can understand limits, and also combinations of those limits. So if anyone knows why certain combinations work and why others don't please feel free to direct me to the correct source of information on where I can learn this. Example: Topic - For loops What is a for loop How to use a for loop why a for loop only works in etc why it doesnt
@muhammedmustafa76852 жыл бұрын
for i in range(1, 11): print(tafel, 'x', i, '=', tafel*i)
@benlong10803 жыл бұрын
Hey, awesome and informative vid! I like the challenges included. But quick question. I ran my code: for even_num in range (1, 9, 2): print(even_num) print("We ......") And it was successful. I wish I would have written the more sophisticated way, but can you tell me how mine would not function the same ultimately? Thanks!
@chunyiptaxi Жыл бұрын
thanks for your clear explanation
@bigtomDW3 жыл бұрын
the for loops are explained sooo well. but i still have my days when i cannot for the life of me wrap my head around it
@priyankadhage70010 ай бұрын
This only video helped a lot . Thanks
@muhammedmustafa76852 жыл бұрын
if (getal % 3 == 0): print('Deelbaar door 3') else: print('Niet deelbaar door 3')
@LifeWithSeb995 жыл бұрын
My solution is slightly different, have a look: h = int(input("Enter Number: ")) y = range(1, h) for x in y: if x % 2 == 0: print(x) z = (len(y)) // 2 print("we have ", z, " even numbers between 1 and ", h)
@swallowedinthesea114 жыл бұрын
Good, good! I like it when people take the time to find unorthodox ways to solve problems. It trains your mind. 'Be like water' ~ Bruce Lee. 06202020
@drei46414 жыл бұрын
The fact that I was able to mostly understand this as a full beginner makes me proud of all the thinking I did while learning
@sarahaddady60444 жыл бұрын
I was wondering if at 13:34 we could have the below code instead: for number in range(2,9,2): print(number) print(f"we have 4 even numbers")
@swallowedinthesea114 жыл бұрын
Yes! But in the real world it would be different. range(2,9,2): *^you have already figured out the even numbers by adding STEPS.* range(1, 10) *^you could get an interview question asking you to find all the even numbers but not by using STEPS like you had earlier. A good programmer should first learn how to do things the not-so-easy peasy lemon squeezy way, but learn the long way first to train your mind. 'Be like water. ~ Bruce Lee* 06202020
@pcharl016 ай бұрын
I was hopefully watching this would help me with my crash course in python on coursera. I'm not sure if I'm there yet.
@HimanshuSharma-oy9ss4 жыл бұрын
Hello mosh ! I'm taking your free 6 hours python course. But when i tried to solve the 'sum total of prices' problem , even when i typed exactly what you did in the video, my result were iterative instead of a single integer value ( the actual expected sum total ). Is there any settings that i have to change in pycharm ?
@Ohamskillua3 жыл бұрын
you should check for capital letters make,and also check for indexation,python is case hsensitive
@iyazbhat82134 жыл бұрын
In which VSCode Extension you're running code, if it's other then Terminal.
@nguyenloc26343 жыл бұрын
Excuse me sir ! Do you have some basic exercises in Python?
Thanks for this tutorial, but is it possible to make a loop for the numbers (for example: 0, 1, 2, 3, 4), but starting with 43? (for example 43, 44, 45, 46, 47)
@neveyom88692 жыл бұрын
u can if you do this for I in range(43,50,1) btw I am not professional i am 12 but this should work
@zbynk8102 жыл бұрын
@@neveyom8869 thanks, I'm just 2 years older than you, so you're not alone
@neveyom88692 жыл бұрын
Sure (ノ◕ヮ◕)ノ*.✧
@kevinflynn48672 жыл бұрын
Thank you Sir ! Your video were very helpful
@danjkp15732 жыл бұрын
3 hours lecture class < 15 Minute with mosh
@ocraking8 ай бұрын
Great tutorial, many thank yous haha ;)
@neerajnegi3517 Жыл бұрын
Really easy to understand
@karimabrini6 жыл бұрын
Thanks Mosh easily explained
@karimabrini6 жыл бұрын
@@programmingwithmosh beginner
@mohammadanarul6245 жыл бұрын
thank you sir..
@yusufmiftahudeen2 жыл бұрын
You are a great explainer, May Allah guide you to paradise AMEEN
@freehappymeal2 жыл бұрын
I like the way you explain this concept. It helped to see what was going on in the nested loop.
@metmekujone33313 жыл бұрын
i am grade 10 when i was 9 i hate ict now i have interest for python because u guy here WITH ME !!!! M=THANK YOU SO MUCH FOR UR HELP print("M*1000000000000000000000000000000")
@daviddean5512 Жыл бұрын
why for the final example can't you just write for x in range(2, 10, 2): print(x) print("We have 4 odd numbers") Is it because if the interval was something like (2, 198534, 2) you could write the wrong amount
@Multifandomguy4 жыл бұрын
7:23 why it didn’t work with me ?
@aniketvarshney40384 жыл бұрын
In print function why have we used f" print(f"{x}, {y})
@Puginator214 жыл бұрын
So that you can insert the {x} and {y}. Without the f in front of the " it would just print "{x}, {y}", without inserting the actual numbers.