Try these exercises for more practice with relational and logical operators.
1. Understanding Boolean Logic
Booleans represent the truth values that are associated with the logic branch of mathematics, which informs algorithms in computer science. Named for the mathematician George Boole, the word Boolean always begins with a capitalized B. The values
True
and
False
will also always be with a capital T and F respectively, as they are special values in Python.
In this tutorial, we’ll go over the basics you’ll need to understand how Booleans work, including Boolean comparison and logical operators, and truth tables.
Source: Lisa Tagliaferri, https://cuny.manifoldapp.org/read/how-to-code-in-python-3/section/01a1ddd6-7664-418a-adf5-1c3c369ad6c5#understanding-boolean-logic This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 License.