Advertisements
Advertisements
Question
Assertion (A): The output of print(df) and print(df.loc[:]) will be same for a DataFrame df.
Reason (R): The statement print(df.loc[:]) will display all rows and columns of the DataFrame df, thus showing the entire data.
Options
Both A and R are True, and R correctly explains A.
Both A and R are True, but R does not correctly explain A.
A is True, but R is False.
A is False, but R is True.
MCQ
Assertion and Reasoning
Advertisements
Solution
Both A and R are True, and R correctly explains A.
shaalaa.com
Is there an error in this question or solution?
