and and in python code example
Example 1: and in python
#And opreator in python
a = 12
b = 56
print(a and b * 12)
Example 2: logical operator in python
# logical and operator
# return first operands if false otherwise second operands
0 and 3
# output = 0
3 and 0
# output = 0
3 and 5
# output = 5
Example 3: x and y in python
x > y is False
x < y is True
x == y is False
x != y is True
x >= y is False
x <= y is True