Complete the code to select rows where the 'age' column is greater than 30.
filtered = df[df['age'] [1] 30]
We use the '>' operator to select rows where 'age' is greater than 30.
Complete the code to select rows where the 'score' column is equal to 100.
perfect_scores = df[df['score'] [1] 100]
The '==' operator checks for equality, so it selects rows where 'score' is exactly 100.
Fix the error in the code to select rows where 'height' is less than or equal to 170.
short_people = df[df['height'] [1] 170]
The correct operator for 'less than or equal to' is '<='.
Fill both blanks to create a dictionary comprehension that maps words to their lengths only if the length is greater than 3.
{word: [1] for word in words if [2]The dictionary maps each word to its length (len(word)) only if the length is greater than 3 (len(word) > 3).
Fill all three blanks to create a dictionary comprehension that maps uppercase words to their scores only if the score is greater than 50.
{ [1]: [2] for word, score in data.items() if [3] }The dictionary keys are uppercase words (word.upper()), values are scores, and only scores greater than 50 are included.