In this lesson, we'll learn about logical operators in Python. Logical operators are used to combine conditional statements and control the flow of decision-making and output Boolean values. Below is a list of logical operators.
and - Returns true if both values are true.
or - Returns true if at least one value is true.
not - Returns true if the condition is false.
Here is an example
Input:
x = 10
print(x>5 and x<20)Output:
True