In this course, you learned about conditional statements and conditional logic. You saw how to compare values using comparison operators like
==. You also saw how to build complex conditional statements using
Next, you saw how to control the flow of your program using
if statements. You learned how to create branches in your program using
else. You also learned how to control precisely how code is executed inside an
if block using
You learned about the
except pattern to handle errors that may occur during runtime. This is an important construct that allows your programs to handle the unexpected gracefully and keep users happy that the program didn’t crash.
Finally, you applied the techniques that you learned in this course and used the
random module to build some coin toss simulations.
For more information on the concepts covered in this course, check out the following tutorials:
- Conditional Statements in Python
- Using the “and” Boolean Operator in Python
- Using the “or” Boolean Operator in Python
- Using the “not” Boolean Operator in Python
- Python “for” Loops (Definite Iteration)
- Python “while” Loops (Indefinite Iteration)
- Python Exceptions: An Introduction
Or you can explore the following video courses:
- Conditional Statements in Python (if/elif/else)
- Using the Python and Operator
- Using the Python or Operator
- Using the Python not Operator
- For Loops in Python (Definite Iteration)
- Mastering While Loops
- Raising and Handling Python Exceptions
To continue your Python learning journey, check out the other Python Basics courses. You might also consider getting yourself a copy of Python Basics: A Practical Introduction to Python 3.
Congratulations, you made it to the end of the course! What’s your #1 takeaway or favorite thing you learned? How are you going to put your newfound skills to use? Leave a comment in the discussion section and let us know.