March 2019
Intermediate to advanced
640 pages
23h 40m
English
Objectives
In this chapter, you’ll:
Make decisions with if, if else and if elif else.
Execute statements repeatedly with while and for.
Shorten assignment expressions with augmented assignments.
Use the for statement and the built-in range function to repeat actions for a sequence of values.
Perform sentinel-controlled iteration with while.
Create compound conditions with the Boolean operators and, or and not.
Stop looping with break.
Force the next iteration of a loop with continue.
Use functional-style programming features to write scripts that are more concise, clearer, easier to debug and easier to parallelize.
Outline
Read now
Unlock full access