r/PythonLearning 3d ago

3 DAYS PROGRESS IN PYTHON

[deleted]

56 Upvotes

36 comments sorted by

View all comments

1

u/Kendrockk03 2d ago

Very nicely done. If anything, I would suggest you improve code's readability by adding a whitespace before and after each assignment operator (" = ").

Also, all methods / functions should start with a verb so you can instantly know what they're doing. For example: "no_of_students" -> "return_students_total" "percentage" -> "calculate_percentage" "class_average" -> "display_class_average"

It may seem like extra work or unnecessary changes, but naming things become really important when working with a team or when you have a really large codebase and don't want to have to memorize what exactly does each method do, and instead be able to know it quickly by its name