Skip to content

Commit 21a1311

Browse files
authored
Create 2885. Rename Columns.py
1 parent 9c98d75 commit 21a1311

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

2885. Rename Columns.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
def renameColumns(students: pd.DataFrame) -> pd.DataFrame:
2+
return students.rename(
3+
columns={
4+
'id': 'student_id',
5+
'first': 'first_name',
6+
'last': 'last_name',
7+
'age': 'age_in_years',
8+
}
9+
)

0 commit comments

Comments
 (0)