I'm leaving my current $work, and changing to another one. Being the first one I'm starting not as an university student but a 'professional' one feels strange, and I'm somewhat thrilled. Will I be good enough for the job? I hope so :)
These last days I'm reviewing some of my old code with the guy who will inherit my codes. A cool programmer, with lots of knowledge I wouldn't expect from an average young programmer (it's actually a bit older than me but, you know... not everyone reads 'refactoring', code complete, and GoF just for fun :) ). We've had good times. Transfering info would be quite more difficult without such a good learner. In little less than a week, he also explained me some ins and outs about some agile methodologies, or good programming practices (some cool refactorings, Log4X modules, etc...). We both learned quite a lot from each other.
Some of the neat advices that I liked.
- use Logging modules. They pay off. And they are quite easy to set up (opposed to what I thought)
- refactor any piece of code that is repeated more than 1 time (if it's easy to do). calling a simple join(',' , @array) three times in the same function can be refactored into a meaningful name sub. You get the name explaining what your code does, and if you want to change ',' to ':', only one change does it.
- Codes that you write separated by 2 newlines, like paragraphs, and start with a comment that explains what that snippet does, are screaming for a new function. You can use the first words of the comment as a hint for the function name.
- Take a look at AOP, it's cool. a really cool thing.
Suscribirse a:
Enviar comentarios (Atom)
1 comentario:
Good luck at your new job!
Funny, I have been reading about AOP the past two days. A lot of meta-programming and other cool stuff are involved.
BTW, I write a lot of code separated by paragraphs and starting with a comment, I will take the advices for myself. Something I always loved about Smalltalk is that you rarely face more than ten lines of code at once. This advices seems good for getting that into any programming language.
Publicar un comentario