B10 - list comprehension

def main():
    yell("This", "is", "CS50")

def yell(*words):
    uppercased = []
    for word in words:
        uppercased.append(word.upper())
    print(*uppercased)

if __name__ == "__main__":
    main()```

- using `map`, the above function can be simplified

```python
def yell(*words):
    uppercased = map(str.upper, words)
    print(*uppercased)
uppercased = [arg.upper() for arg in words]
students = [
    {"name": "Hermione", "house": "Gryffindor"},
    {"name": "Harry", "house": "Gryffindor"},
    {"name": "Ron", "house": "Gryffindor"},
    {"name": "Draco", "house": "Slytherin"},
]

gryffindors = []
for student in students:
    if student["house"] == "Gryffindor":
        gryffindors.append(student["name"])

for gryffindor in sorted(gryffindors):
    print(gryffindor)

griffindoes = [student for student in students if student["house"] == "Griffindor"]