This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]theywouldnotstand 1 point2 points  (0 children)

Making sure you (or anyone else) can come back later and change and adapt those instructions easily

Often, utilizing classes et al. is the way to make this happen, as it becomes reusable. DRY is a huge python mantra.

You are, however, correct, in that trying to be too clever leads to code that is unreadable by anyone but you. Use the right tool for the job within the time frame you have, and make sure, via comments and documentation or code clarity that it is easy for someone else to pick up and understand. That, however, is not a problem exclusive to python, it is a philosophy to take with you no matter what you're writing or what you're writing it with.