Conditional Statements & Loops: While Loops in Python

Python 3.0
  • 11 Videos | 1h 24m 2s
  • Includes Assessment
  • Earns a Badge
Likes 212 Likes 212
While loops are one way to keep repeating a set of actions until a specific condition is met in Python. In this 11-video course, learners explore the use of while loops, considerations when implementing while loops, and use cases for while loops and for loops. Key concepts covered here include implementing a basic while loop and recognizing what conditions cause it to become an infinite loop; learning to use while loops to carry out actions while evaluating expressions based on numerical and string data; and examining while loops whose iterations depend on user input data. Next, learn syntax for defining while loops within a single line; learn to iterate over a list of elements with while loops; and learn to iterate over multiple lists and tuples with while loops. Learn when it is appropriate to use break keyword to stop a while loop, and learn to break out of a while loop and recognize use of the pass keyword within such loops. Finally, learn skip steps in individual iterations of a while loop using the continue statement.

WHAT YOU WILL LEARN

  • discover the key concepts covered in this course
    implement a basic while loop and recognize what conditions can cause it to become an infinite loop
    use while loops to carry out actions while evaluating expressions based on numerical and string data
    define while loops whose iterations depend on user input data
    recall the syntax for defining while loops within a single line
    iterate over a list of elements using while loops
  • iterate over multiple lists and tuples using while loops
    identify when it is appropriate to use the break keyword to stop a while loop
    use the break statement in multiple scenarios to break out of a while loop and recognize the use of the pass keyword within such loops
    skip steps in individual iterations of a while loop using the continue statement
    compare while loops and for loops and implement a while loop which terminates only when the user enters a specific input

IN THIS COURSE

  • Playable
    1. 
    Course Overview
    2m 23s
    UP NEXT
  • Playable
    2. 
    An Introduction to While Loops
    9m 22s
  • Locked
    3. 
    Basic While Loops - Part 1
    4m 18s
  • Locked
    4. 
    Basic While Loops - Part 2
    6m 21s
  • Locked
    5. 
    Single-line While Loops
    8m 24s
  • Locked
    6. 
    Evaluating Complex Data with While Loops - Part 1
    8m 46s
  • Locked
    7. 
    Evaluating Complex Data with While Loops - Part 2
    9m 8s
  • Locked
    8. 
    Exit a While Loop Using the Break Statement
    9m 55s
  • Locked
    9. 
    Using the Pass Keyword in a While Loop
    8m 36s
  • Locked
    10. 
    The Continue Statement in a While Loop
    6m 21s
  • Locked
    11. 
    Exercise: While Loops in Python
    5m 57s

EARN A DIGITAL BADGE WHEN YOU COMPLETE THIS COURSE

Skillsoft is providing you the opportunity to earn a digital badge upon successful completion of this course, which can be shared on any social network or business platform

Digital badges are yours to keep, forever.

PEOPLE WHO VIEWED THIS ALSO VIEWED THESE