October 2023
Beginner to intermediate
215 pages
4h 3m
English
This chapter shows you various types of loops in Python, such as for loops and while loops. You will also see examples of nested loops.
The first part of this chapter explains the precedence of operators, followed by a section that contains reserved words (i.e., words that you cannot use as variables in your Python code).
The second part of this chapter briefly discusses lists and various operations that you can perform on lists. This material is helpful for code samples involving lists that are discussed in subsequent chapters.
The third part of this chapter discusses for loops, along with code samples that show you how to use a try/except code block in a for loop. You will also see an example of a nested loop. ...
Read now
Unlock full access