Coding acronyms Thursday, April 15, 2010

Sometimes I feel pretty accomplished. Then I remember how often I have to sing myself the alphabet song.

Recently my project manager has been throwing acronyms at me, "Is that base class SOLID," "You need to DRY up that code," "you ain't gonna need it"etc. etc. Oddly enough, I'm the type of person that repeats that kind of stuff over and over again in my head (like the alphabet song), it's probably related to my mild OCD. But I've found that it actually helps me to write better code!

Obviously memorizing a few acronyms aren't going to make you a genius programmer, you have to actually understand the principles behind them, and be able to apply them. It takes learning and practice, but the rewards are well wroth it IMAO.

DRY: Don't Repeat Yourself
YAGNI: You Ain't Gonna Need It
S.O.L.I.D.:
 S: Single Responsibility (PTOM: The Single Responsibility Principle by Sean Chambers)
O: Open Closed (open to extension closed to modification)
L: Liskov Substitution (PTOM: The Liskov Substitution Principle)
I: Interface Segregation
D: Dependency Inversion (and/or Injection)

0 comments:

Post a Comment

Annual Scott Gu event