SOLID principles
Five design principles, collected by Robert Martin, aimed at making designs more understandable, flexible and maintainable. The letters spell a mnemonic:
Applied mindlessly, they cause more harm than good. Every one of them buys flexibility with indirection, and there is probably no successful product where all five are applied everywhere at once. Strive for them, stay pragmatic, and treat none of it as dogma - each page linked above ends with the cases where that principle is the wrong tool, the design patterns in this site's catalog that exist mainly to satisfy it, and a second worked example in a different domain so the idea does not stay welded to one story.
None of the five stand alone, either. Open/closed usually gets satisfied by reaching for Strategy or Decorator; dependency inversion is what Dependency Injection is for; a class that violates single responsibility is often also the class that turns out hardest to keep open/closed, because two reasons to change means two chances for a new requirement to force a rewrite instead of an extension. Read them in order once, then treat each page as a reference to come back to.
Spot the smell
Five snippets, each lifted straight from the "where it goes wrong" examples across the five pages above. Pick which principle each one breaks before checking your work.