I’ve noticed a recurring trend in the way that I learn new concepts which doesn’t seem to fit exactly into any of the models of learning that I have come across so far.
It seems to me to be a learning cycle which goes something like this:
- Don’t know what is good and what’s bad
- Learn what’s good and what’s bad but don’t know how to fix something that’s bad
- Learn how to make something that’s bad good
The two areas I have noticed this have both been related to concepts about writing clean code.
When I first started writing code I couldn’t tell the difference between testable and untestable code. After my first project I became more aware of patterns that led to untestable code but I wasn’t able to make untestable code testable. Finally after working on a couple of projects I had worked with enough people and shown enough tips that I have a reasonable idea of how to get difficult to test code into a state where we can put some kind of tests around it.
I noticed the same trend more recently when discussing how to write truly object oriented code. Initially I wasn’t aware that suffixing classes with ‘Manager’ or ‘Helper’ was a code smell until I came across Peter Gillard-Moss’ post about this. Having become aware of this I started noticing this in code bases that I worked on but I still couldn’t see how to fix it. I’m not completely in the 3rd part of the learning cycle yet but I am more aware when creating classes to focus on what they are not what they do when it comes to naming, to think about the classes responsibility and so on.
I think it is closest to the Four stages of competence, closely relating to each of the first 3 stages. I’m not sure how the unconscious competence stage would fit in though.
At the moment I’m using the pattern to raise my awareness of where I currently am for different skills and to help me move from stage 2 to stage 3.