Q. Write a program to display number of rows and number of columns in DataFrame df.


Answer :-

import pandas as pd
#Series object df created or loaded
print("No. of rows: ", df.shape[0])
print("No. Of columns : ", df.shape[1])

Post a Comment

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

Previous Post Next Post