Download our e-book of Introduction To Python
Pallavi Dhotre
2 years ago
a=10
b=5
c=10
d=5
print(a>b and c>d) # both conditions are true
print(a<b and c>d) #1st condition is true second is false
print(a>b and c<d) #1st condition is false second is True
print(a<b and c<d) #both conditions are false
True
False
False
False
a=10
b=5
c=10
d=5
print(a>b or c>d) # both conditions are true
print(a<b or c>d) #1st condition is true second is false
print(a>b or c<d) #1st condition is false second is True
print(a<b or c<d) #both conditions are false
True
True
True
False
a=10
b=5
c=10
d=5
print(not(a>b)) # actual result of a>b is true
print(not(c<d)) # actual result of c<d is false
False
True