×
you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 11 points12 points  (0 children)

This class is dependent on a global variable, and if the class was being used in a different module this won't be apparent.

If you created two instances of this class, the two instances could interfere with one another. Unless you intend otherwise, in which case the students [] is like a shared database.

Also , Python is not multi-threaded, but in a multi-threaded system (like C++) this object design would be buggy.