pandas de modo imputivo

cols = ["workclass", "native-country"]
df[cols]=df[cols].fillna(df.mode().iloc[0])
DS in Training