LearnPy Hub
← Pandas: DataFrames problems
Easy

Rows and Columns

Load the students into a DataFrame and print its shape and its column names as a list.

Input

Lines 'name dept cgpa credits', then END.

Output

Two lines.

Sample 1

Input
Mim CSE 3.82 120
Rafi EEE 3.41 98
Sara CSE 3.95 132
Tuhin BBA 3.60 110
Nadia CSE 3.71 125
END
Output
(5, 4)
['name', 'dept', 'cgpa', 'credits']

Sample 2

Input
A CSE 3.00 100
END
Output
(1, 4)
['name', 'dept', 'cgpa', 'credits']
solution.py
Output appears here
Rows and Columns · Python practice problem · LearnPy Hub