1# Create variable with TRUE if nationality is USA
2american = df['nationality'] == "USA"
3
4# Create variable with TRUE if age is greater than 50
5elderly = df['age'] > 50
6
7# Select all cases where nationality is USA and age is greater than 50
8df[american & elderly]