My impression of the first three weeks differed as the weeks go by. In the first two weeks, everything was simply a review of CSC108. The professor reviewed the concept of class, and the steps required to design a new class (i.e. begin by writing the __init__() and initialize variables). Furthermore, special methods such as str(), eq() and repr() was discussed in further detail. In the later week, the class was introduced to property, which is Python’s built-in function used to intercept all code that assigns to coord and passes that off to _set_coord. Basically, the property mechanism prevents clients/users that use my code from changing certain private attributes. Next, the class learned about one example of abstract data types (ADTs) called stack. Essentially, stack is a data storage mechanism that can store a variety of objects. Furthermore, in a stack, new items can be pushed onto the top of the stack, while items at the top are always removed first.
So far, the concepts being taught in class can be easily comprehended; however, the topics taught in the third week became significantly more difficult. Before I had the time to reaffirm my knowledge, assignment 1 was being handed down. To my devastation, the one concept that I didn’t grasp thoroughly, inheritance, was implemented heavily in the assignment. Inheritance is the idea that new classes (called subclass) can be built based on already existing classes (called parent class) by extending the existing class’s methods, or by overriding the methods. When extending methods from the parent class, the subclass automatically inherits the attributes and codes from its parent. Contrarily, overriding existing methods in the parent class means changing the existing methods into something else, and then only implement it within the subclass. Lastly, new methods can be simply added to the subclass. Despite my understanding of inheritance, it is not enough for me to complete assignment 1. This is because I had trouble grouping the methods and attributes that are common to all subclasses into the generic parent class, and leaving the distinct attributes to the subclasses. Even more frustrating was that every time I leave office hour with professor’s feedback, I always ended up making huge modifications to my program.
In conclusion, my impression of the first three weeks changed as I gradually learned deeper into the concept of object oriented programming. Classes became more difficult as the Prof began teaching new materials that was never mentioned in CSC108. Moreover, my schedule is thrown into chaos as Assignment 1 came crashing down before I had any preparation. Everything was a frenzy as I try to assimilate into the new learning environment. Before, in CSC108, the knowledge was being handed down on a silver platter; however, in CSC148, the Professor actually leaves out some materials for us to comprehend on our own. Hence, my final impression of the first three weeks was a chaotic madness as I tried to get used to new professors, and new and difficult materials.

No comments:
Post a Comment