FOR Loop in Python (Syntax, Break, Continue, Else, Nested Loop, Range, Index) - Python for Beginners

Поделиться
HTML-код
  • Опубликовано: 5 сен 2024

Комментарии • 65

  • @DigitalAcademyOnline
    @DigitalAcademyOnline  4 года назад +6

    🎯In this video, you will discover multiple way to control the execution flow of your program, using FOR loops. Then, you will learn how you can alter the execution of an iteration with: BREAK, CONTINUE and ELSE statements.

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  4 года назад +2

      When you iterate over a list using for Loop, you may also want to use the enumerate() function, so that you can get both the index of your item, and its associated value.
      my_list = ["a", 1, True]
      for index, item in enumerate(my_list): print(index, item)

  • @0xJ3r3my
    @0xJ3r3my 4 года назад +4

    One of the best Tutorial on Python FOR Loops that I have ever seen 👌🏻

  • @Shorts-fr3zf
    @Shorts-fr3zf 4 года назад +3

    I found this video best of best over youtube. But plz add some complex examples as well. So we can understand complex problems for our future.

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  4 года назад +2

      Heyy, Thanks so much for your feedback, I do really appreciate it 🙏🏻 I am glad that you liked this video, it means a lot! And I take note about more complex and also advanced examples / exercises 📝

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  3 года назад +1

      ALL Basics in Python for Beginners have been covered into ONE single Tutorial. If you wanna check it out - it’s all yours 😊 Enjoy it and share it if you want Amir

  • @lalajt7469
    @lalajt7469 3 года назад +1

    Amazing video, thanks 👍

  • @metalgameryt4872
    @metalgameryt4872 4 года назад +3

    Txx to explain

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  4 года назад +3

      You are welcome! 🙏🏻

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  4 года назад +2

      What did you like most? Did you find it easy to understand, and this exercise useful? 🤔

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  3 года назад +1

      ALL Basics in Python for Beginners have been covered into ONE single Tutorial. If you wanna check it out - it’s all yours 😊 Enjoy it and share it if you want 😉

  • @living_joyfully
    @living_joyfully 4 года назад +3

    Thanks for making videos like this 😊

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  4 года назад +3

      Aww, Thaank you sooo so much for your feedback and such a nice comment, I do reallyy appreciate it! 🙏🏻 If you want to be part of this community and also discover new videos, like this one, do not forget to subscribe this channel 😊

    • @living_joyfully
      @living_joyfully 4 года назад +3

      @@DigitalAcademyOnline Already subscribe

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  4 года назад +3

      Thaaanks for being part of my 1st 1K subscribers! NEW videos are going to be released in a near future - Stay tuned!

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  3 года назад +1

      ALL Basics in Python for Beginners have been covered into ONE single Tutorial. If you wanna check it out - it’s all yours 😊 Enjoy it and share it if you want, Sahil

  • @deutschvalley3574
    @deutschvalley3574 4 года назад +2

    Sir great job you solve my doubts and fearness now i am eager to more learn 😍 i am so happy and bundles of thanks

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  4 года назад +3

      Heeyy there 👋🏻 Wow, such a warm and kind message, thanks for your feedback, I do really appreciate a lot! 🙏🏻 I am glad this video helped you out understanding for loops in Python, and that you are now willing to learn even more. Welcome in this community, spread the words 😊

    • @deutschvalley3574
      @deutschvalley3574 4 года назад +2

      @@DigitalAcademyOnline Dear sir most welcome kindly make on API and fetch the da also on database

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  4 года назад +3

      I take good note of your request! 👍🏻 As soon as Basics have been covered, I will schedule new videos, about Web Dev in Python, and Database Query

    • @deutschvalley3574
      @deutschvalley3574 4 года назад +2

      @@DigitalAcademyOnline waoo really appreciated sir i am waiting for your upcoming Vidoe not more wait :)

    • @0xJ3r3my
      @0xJ3r3my 4 года назад +3

      Kaka Pak I do agree, We would love videos about Web Development then

  • @chloejbt4775
    @chloejbt4775 3 года назад +1

    Great videos

  • @vishiram6
    @vishiram6 4 года назад +2

    I wish I learn easily from your videos. Will leave my suggestions and comments at end of video.

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  4 года назад +2

      Heyy, I do really hope you liked this video and you are willing to watch even more! I do really appreciate your feedback 🙏🏻

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  4 года назад +2

      What did you like most? NEW videos are going to be released in a near the future! Thanks so much for being part of my 1st 1k subscribers - Stay tuned! ☺️

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  3 года назад +1

      ALL Basics in Python for Beginners have been covered into ONE single Tutorial. If you wanna check it out - it’s all yours 😊 Enjoy it and share it if you want, Vishwanath 😉

  • @sonymartin6402
    @sonymartin6402 2 года назад +1

    do you have a video for functions? i am struggling with the for loops and using functions i am looking for additional help thanks

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  2 года назад +1

      Heyyy there 👋🏻

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  2 года назад +1

      Of course, this channel aims to help people learn Python, from Beginners to Advanced 🐍

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  2 года назад +1

      You will learn how to create a function, call a function, numerous ways to pass arguments to your function, but also how to return a value - and much more
      👇🏻 Functions are covered in this video:
      ruclips.net/video/ZKjYBo89i64/видео.html

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  2 года назад +2

      But if you still need some help or have any question, please let me know 😇

    • @sonymartin6402
      @sonymartin6402 2 года назад +1

      @@DigitalAcademyOnline thank you just bunches

  • @mytube9036
    @mytube9036 2 года назад +2

    Hi I want u to help me in something I want to make a multiplication project using function and for loop so this is my project
    I wrote Def multiplying (place) :
    Print("the multiplication table of your number",num,"is")
    Print(num,"x",m,"=",num*m)
    For m in range (13):
    num=int(input("enter your number to get its multiplying table: "))
    multiplying("made by moaaz")
    So this is my project the problem when I run it and I enter the number like 4 or any number it shows me 4x0=0
    But not showing its multiplying table

    • @mytube9036
      @mytube9036 2 года назад +1

      So pls tell me if I made a problem here or the codes places are wrong

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  2 года назад +1

      Heyyy there. Warmest wishes this this New Year - hope you're doing well. Sorry for the late reply, I have been very busy lately

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  2 года назад +1

      So, Basically, there is one statement located at the wrong place. I mean, if you want to get the multiplying table of "num", you need to print m times "num x m = " num * m. That's why you are doing for loop and call multiplying() every time...

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  2 года назад +1

      Nonetheless, You are also asking the user to give a number on every iteration of the for loop. If you give a new number every time, you should see that m is incrementing

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  2 года назад +1

      Basically, your only error here is to ask the number every time. If you can move this statement before the for loop, everything should be fine with your code 👍🏻

  • @chloejbt4775
    @chloejbt4775 3 года назад +1

    🙏

  • @chloejbt4775
    @chloejbt4775 3 года назад +1

    ✌️

  • @alexanderpadalka5708
    @alexanderpadalka5708 3 года назад +1

    🗽

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  3 года назад +2

      I hope this video was helpful and you understood How FOR Loops work in Python. This exercise was not too difficult, was it?

    • @alexanderpadalka5708
      @alexanderpadalka5708 3 года назад +1

      @@DigitalAcademyOnline Thanks a million! No, not difficult everything great!

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  3 года назад +2

      Well, You are a quick learner 💪🏻

  • @PassionsByCath
    @PassionsByCath 4 года назад +2

    :-)

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  4 года назад +2

      Thaank you for supporting and being an active member of this community! ☺️

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  4 года назад +2

      Quelle vidéo avez-vous préféré ? Qu'avez-vous pensé d'ajouter un petit exercice pratique, au sein de chaque vidéo ?

    • @PassionsByCath
      @PassionsByCath 4 года назад +2

      @@DigitalAcademyOnline merci pour ces vidéos très ludiques et enrichissantes aussi bien pour débutant que pour se perfectionner. Les exercices permettent de vérifier les acquis, c'est un plus très intéressant.

    • @DigitalAcademyOnline
      @DigitalAcademyOnline  4 года назад +2

      Je suis ravi que les vidéos vous plaisent. N’hésitez pas à en parler autour de vous et partager la chaîne, si l’envie vous dit :)

    • @0xJ3r3my
      @0xJ3r3my 4 года назад +2

      Definitely one of the best channel I have ever crossed my path with! It deserves a LOT more views👌🏻