I will now discuss the format that object-oriented programming usually uses. Classes are self-defined by the programmer to represent the desired object. Each class uses a special method called __init__ to initialize attributes of the objects as instance variables. When does this happen? The __init__ method is called immediately when the constructor of the class is called which is the same name as the class with ( ) added to the end. This process is known as instantiation and finishes the storing information aspect of object oriented programming. The next step is to create methods in the class to manipulate the information stored in the instance variables and get the desired output. In object-oriented programming, think of it as that the object uses the method and not the method using the object as in procedural programming. It makes more sense for a dog to play than play to use the dog. This is the clarity that object-oriented programming provides for the coder and the reader.
Object-oriented programming to me isn't a new concept as I programmed a tic-tac-toe game in Java with my class in 2013. Programming an interactive tic-tac-toe game that connected students to each other in the classroom isn't easy and with procedural programming paradigm, the code would have been all over the place. However, the use of classes with defined objects made each of the mini tasks that build the tic tac toe game much easier to code and organized the code into separate modules that can be accessed when required. Constructors, initializers, methods, and inheritance are some of the features that object-oriented programming provide for the coder and allow big projects to be built from smaller objects much easier. In my opinion, object-oriented programming is a very powerful style and will continue to be used by many coders in the future due to its flexibility, organization, and informative code.
