Python3 : Beginner - Loops
Hi - first of all, excuse my english : i'm french ! And also a beginner in python3 I have an exercise : 1 - make a list of people (first name + last name) 2 - ask for a random letter 3 - if the random letter equals the first letter of the first name, the guy wins. And it can be two or more winners 1 - Here's my list : studentList = [ "Edmond Prochain", "Sam DĂ©mange", "Sandra Nicouette", "Jordy Nateur", "Emmy SphĂšre", ] 2 - here's how I call the random letter : import string string.ascii_uppercase import random my_letter = random.choice(string.ascii_uppercase) 3 ... that's the most important part and I'm confused ... I was considering doing a "for" + "if" but i can't find how to code : "if the random letter equals the first letter of the first name : return the list of the winner(s)" I'm not asking for all the solution, just some help Thanks a lot !