Monday, August 25, 2008 6:51 PM
Whenever I tell one of my developers to do something a certain way I always get asked the question "why? doesnt it just take longer?". Well maybe it takes a little longer but Its not just because i am being a hard ass there is method behind my madness.
1. Format your code for readability:
Sure, you may understand your code inside out and know exactly what its doing but its may not always be you who has to edit the code. A few extra line breaks, proper tabbing, pretty code makes all the difference when someone else is burdened to read, understand and edit it.
2. Stick to the naming convention:
EUGHStrUPINSET, frmTest, cDataStructures, customerInformation whatever your convention, stick to it, its there so you all understand what a variable does. But IMHO dont let your naming convention be visibleĀ on public members stick to Camel Cased strings.
3. That super new functionality may be cool but...
Not everyone in your team may not understand it so whereas you maybe an ub3r l33t coder for using it. You just lost 2 days while everyone else now has to learn it. Thanks!
4. Comment it please:
It may seem straight forward but itsalways nice to know what you intended it to do just incase you wrote it with a hangover and its not doing anything slightly like what it should, if its purpose isnt commented who knows if its right or wrong.
5. Put order in your code and use #region #endregion blocks:
Why? For the meer reason I said so, I like it and it makes me happy 