Q. Which pandas method is used to change column names in-place?
β
Correct Answer: (B)
rename(columns=..., inplace=True)
Explanation: By using rename() with the inplace=True argument, the column names can be modified directly in the existing DataFrame.