demo_list_in.py:
thislist = ["apple", "banana", "cherry"] if "apple" in thislist: print("Yes, 'apple' is in the fruits list")
➜ begtut>python demo_list_in.py
Yes, 'apple' is in the fruits list