After switching careers to being a full-time programmer, I have started to see and realize aspects of programming that truly amaze me. Before starting this job, I worked on PHP and Java what I though was a considerable amount. I was wrong, I only scratched the surface with what these languages can do and I had no idea of their limits.
The real-life example from this week is memory management in PHP. That’s right, I have a html page generated by—what I (and confirmed by my project leader) think is—efficient PHP code which I had to write in memory management code for. I was confused out of my mind for a while, since PHP has built-in garbage collection. After looking at my code further and analyzing what was going on, I started to understand what garbage collection is and what its limits are. Of course though, just because I understand what is going on doesn’t mean that I actually coding memory management is easy. Calling unset() at the right time is key.