import pandas as pd
import numpy as np
def select_nan_rows(df):
return df[df['score'].isnull()]
df1 = pd.DataFrame({'name': ['Tom', 'Jack', 'Steve', 'Ricky'], 'score': [85, np.nan, 87, 91]})
df2 = pd.DataFrame({'name': ['Adam', 'Eve', 'Stark', 'Rogers'], 'score': [88, 92, np.nan, 97]})
print(select_nan_rows(df1))
print(select_nan_rows(df2))