Conditional Statements & Loops: The Basics of for Loops in Python
Python 3.0
| Beginner
- 9 Videos | 1h 1m 26s
- Includes Assessment
- Earns a Badge
Loops are one way to perform the same operations repeatedly in a program. For loops are the control structure to use when the repeated operations are performed on a sequence such as a list or a tuple. In this 9-video course, you will explore different ways to iterate over a sequence using for loops. Key concepts covered in this course include how to use for loops to process elements in a list and characters in a string; and how to code for loops to iterate over values in a tuple and the keys and values in a dictionary. Next, learn the function of associating an else block with a Python for loop; include if-else statements and other for loops within a for loop; how to generate a sequence of consecutive integers with the range function; and how to use the range function to iterate over a large range of values and apply it within nested for loops. Finally, observe how to write for loops in order to iterate over 1-dimensional and 2-dimensional sequences.
WHAT YOU WILL LEARN
-
discover the key concepts covered in this courseuse for loops to process the elements in a list and the characters in a stringcode for loops to iterate over values in a tuple and the keys and values in a dictionaryrecognize the function of associating an else block with a Python for loopinclude if-else statements and other for loops within a for loop
-
generate a sequence of consecutive integers with the range functiondefine the interval in a sequence of increasing and decreasing integers using the range functionuse the range function to iterate over a large range of values and apply it within nested for loopswrite for loops in order to iterate over 1-dimensional and 2-dimensional sequences
IN THIS COURSE
-
1.Course Overview2m 29sUP NEXT
-
2.Iterating over Elements in a List8m 23s
-
3.Iterating over Elements in a Tuple and Dictionary8m 48s
-
4.The else Block of a for Loop7m 23s
-
5.Nested Control Structures in a for Loop6m 41s
-
6.An Introduction to the range Function7m 58s
-
7.Setting Intervals in a Range7m
-
8.Exploring the range Function7m 31s
-
9.Exercise: Basics of Python for Loops5m 15s
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.YOU MIGHT ALSO LIKE

BOOK
The Pythonic Way