How to find an item in a list in Python

preview_player
Показать описание


Code from video:
*****************
company = ['julia', 'erick', 'dillon']
'julia' in company

Connect with us!
*****************
Рекомендации по теме
Комментарии
Автор

Awesome. Clear and straight to the point.

josher
Автор

Could you write the code that uses a list containing three characters and then asks a user to enter a character. The code will then search the list to see if the entered character is in the list or not. If it’s not in the list, then the user is asked to enter a different character. This loop keeps repeating until the user enters a character which IS present in the list.

mcdonaldifill
Автор

I am getting error "SyntaxError: multiple statements found while compiling a single statement"

SK-ubhq