Thursday, January 23, 2014

SLOG Week 3 - Object-Oriented Programming

Object-Oriented Programming is, in my opinion at least, the single most useful computer science concept after the basics. It revolutionizes the way that programs are written by vastly increasing readability and dynamic, non-linear code much easier to write.

I first experimented with Object-Orientation in my grade 11 year, having just learned Java. I made a bullet class and an enemy class; two lists, one for each class, and looped through the lists updating and rendering the bullets and enemies. When an enemy died, I would simply remove it from the lists and continue on my way. Fast forward almost 3 years and I am still using that exact same method (except that i now use inheritance and polymorphism as well).

This year python is completely new to me and though it has it's conveniences, I think that it really just doesn't stand up to Java or C(#, ++, etc). Instead of talking about its downfalls however, I'm going to focus on the things about it that surprised me. For example, I did not know that Python did not have function overloading in the way that Java did. Instead it has the ability to apply default values to parameters which do not necessarily need to be included in the function call.

Something that bothered me not this week, but the last, was the tutorial. The first tutorial lab handout was hard to follow and assuming that you could decipher it, convoluted. This weeks tutorial was much easier to follow though, so I guess things are looking up!