Python not in operator

PHOTO EMBED

Fri Oct 30 2020 20:24:21 GMT+0000 (Coordinated Universal Time)

Saved by @ianh #python #is #not #in

# Python program to illustrate 
# not 'in' operator 
x = 24
y = 20
list = [10, 20, 30, 40, 50 ]; 

if ( x not in list ): 
	print("x is NOT present in given list") 
else: 
	print("x is present in given list") 

if ( y in list ): 
	print("y is present in given list") 
else: 
	print("y is NOT present in given list") 

content_copyCOPY

https://www.geeksforgeeks.org/python-membership-identity-operators-not-not/