Why Do Some Job Descriptions Emphasize Object-oriented Programming?

Question
Why do some job descriptions emphasize object-oriented programming as opposed to procedural programming, scripting or other alternatives?

Background
Some people think that OOP is overused in certain contexts (page 379 of Python 3 Object-Oriented Programming and page 1303 of Programming Python by Mark Lutz). For example OOP may not be ideal for something like regexing (or matching string patterns per page 247 of Python 3 Object-Oriented Programming). However other sources say "… there is no controversy that OOP makes programming easier, faster, more dynamic, and secured." (This quote was taken from nerd.vision.)

Answer
Inexperienced professionals who are new to object-oriented programming tend to use non-object-oriented techniques in programming that they are familiar with. Object-oriented programming is desirable for the following reasons: One, it allows code to be modular and reusable. Two, it allows code to be flexible and extensible. Three, object-oriented code is tied to compilation thus the execution in the CPU is faster. Scripts that are run through an interpreter are not as performant as binary code (compiled code such as .class files). Reusing portions of well-tested code is an efficient practice. OOP involves reusing code.

Moreover, object-oriented programming supports data encapsulation. This benefit of OOP ensures that the code can perform complex and numerous operations on data without the risk of sharing the data. While encapsulation may not be difficult to implement, it generally does not come up in single-pass programming, interactive programming or coding scripts.

There is a legitimate need for some employers' to prefer candidates with object-oriented programming knowledge. For a basic example of object-oriented programming, see this posting. To learn more about object-oriented programming, you may want to read the Gang of Four book also known as Design Patterns: Elements of Reusable Object-Oriented Software. If you want to read when to use a class in Python, see this posting. To test yourself on OOP, take this free quiz.

Leave a comment

Your email address will not be published. Required fields are marked *