Membership ( in, not in ) : Member in : List PYTHON TUTORIALS


PYTHON TUTORIALS » List » Member in »

 

Membership ( in, not in )


mixup_list = [4.0[1'x']'beef', (-1.9+6j)]
print 'beef' in mixup_list
print 'x' in mixup_list
print 'x' in mixup_list[1]

num_list = [1,2,3]
print -49 in num_list
print 34 in num_list
print [65535L2e+030(76.45-1.3j)] in num_list



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


PYTHON TUTORIALS

 Navioo List
» Member in