Coming from a procedural language background, it took me a while to have a better understanding of OOP. At some point, just being able to create a class and then subclass it to extend behavior made me pretty happy. I thought I knew something, until I got to learn a little more about polymorphism, composition, and things like that. Life was good.
Eventually I heard about some OOD principles such as “Open-Closed principle”, “Hollywood principle”, etc., and realized that there was more to it than I had thought. The same happened when I heard about Design Patterns. Actually, let me say that a different way: I had probably heard of those things when I first started working with an OO language, but I wasn’t ready understand and apply those things.
A friend once told me that human beings learn in spiral. That applies to anything really, but I’ll focus on software development here.
The core idea is that a big part of what we learn is not something new, but instead, it’s an improvement to what we had already learned.
For instance, many years ago, I’ve learned a little bit about databases (what tables and columns are, how to create simple databases, etc.). Then, I learned a little bit about classes. As life goes on, I learned about SQL, T-SQL, and that kind of stuff. At that point, I was revisiting my knowledge of databases, but at a higher level then I was when I first looked into it. Eventually I got to learn something about abstraction, so at that point I was revisiting my knowledge of classes.
I’ve tried to put together a visual representation of this, as represented by the image on this post. If you read it from the bottom up, you’ll probably get the idea of what I’m talking about. Say we fast-forward to the point where I was looking into patterns; at that point, I was not only looking into patterns, but I was also revisiting a bunch of things, such as classes, abstraction, inheritance, polymorphism, and principles. I had also already gone through the process of learning about things around databases, and so many other things, so by the time I’m learning something, I’m coming from a cumulative process, where everything I’ve learned thus far will probably affect my understanding of the thing I’m learning (or revisiting), at the moment.
This cumulative process also encompasses the experience gathered from one level to the next. I mean, by the time I got to learn about some OO principles, not only I had learn some of the core OOP principles, and database, and other things, but I had also experienced a lot of that. From the experience comes the notion of challenging my assumptions of when I’ve first learned about something, so that when I revisit it I’ll realize details I’ve missed back then.
On the little figure I’ve put on this post, I’ve added some question marks at the top of the spiral, which tells me I don’t know what the next thing is going to be, but somehow I know it’ll force me to review my currently knowledge of something. For instance, as I get more and more into TDD, I keep revisiting and polishing what I know about OOP. I’ll actually have another post soon regarding my experiences into the test world (unit tests, integration tests, TDD, etc.).
I really dig this learning in spiral thing… 🙂