The isnull() function is used in pandas __________.
The isnull() function is used in pandas __________.
Solution
✅ Correct Option: 1
The isnull() function checks for missing values (NaN or None). It returns a DataFrame of the same shape, with True where a value is missing and False where it is not. Combining it with sum(), as in df.isnull().sum(), gives the count of missing values in each column.
Options 2 and 3: removing a column or row is done by drop(), not isnull().
Option 4: checking whether the whole DataFrame is empty is done by the empty attribute (df.empty), which tests for no rows or columns, not for missing values.
isna() is an alias of isnull() and works the same way.
Related questions:
2025: 21 May Shift 1
2026: 13 May Shift 2