How to check if a value is stored in one of multiple variables in Python

1 Answer

0 votes
a = 'python'
b = 'c++'
c = 13
d = True

if 'c++' in (a, b, c, d):
    print('yes')
else:
    print('no')



'''
run:

yes

'''

 



answered Jul 28, 2022 by avibootz

Related questions

...