BuildlyBuildly
DashboardExercisesProfileHelp
Data Science/Module 2: Data Analytics/Missing Data2/3
Exercise·7 min·10 XP

Drop Rows with Any Missing Value

Context. A CSV came in with some missing values — keep only complete rows.

Your task. Write complete_rows(df) that returns rows where no column has a NaN.

Example. A row with NaN in any single column is dropped, even if all other columns are filled.

Notes. No NaNs anywhere → all rows kept. Every row has at least one NaN → empty DataFrame.

Previous
Filter by Substring (Case-Insensitive)
Next
Fill Missing Values in a Column