Monday, April 6, 2015

Week 12: Last Impressions

Alas the term has finally come to an end. This also means that this post will be my last, and in it I hope to reflect upon the whole course from start to finish, considering the different challenges and triumphs I encountered.

Unlike CSC108, this course is not really a programming course. Even though we dealt with coding for the bulk of the course, our main focus was on understanding concepts such as Object Oriented Programming, Abstract Data Types, Recursion, Big-Oh and efficiency. We may have learned these concepts using Python, but we could have easily done so with any other object-oriented programming language.

Through the course of the term, I didn't really enjoy going to lectures because I didn't have a laptop. I was more thrilled to go to lab meetings where I could work with the code hands-on. Topics that stood out for me were the concepts of Inheritance and Recursion, although I have to say that I enjoyed doing the recursion exercises the most. Doing the lab work really helped me in absorbing the concepts, compared to just looking at lecture slides. 

I relied on my labs when tackling assignments and term tests. In preparing for tests, I spent most of my time going back through them instead of studying my notes. This is why it really sucked when labs got cancelled because of the strike. I know other students relied on labs too to understand lectures better. 

At the end of the day, even with the four week strike, we managed to finish the course! So yay! It was an interesting journey from day one to last, and I hope to learn more in the years to come!

Sunday, March 29, 2015

Week 11: Revisiting an Earlier SLOG Post

I want to revisit my Week 5 post which is about recursion. First of all, I just want to say that I can't believe that the term is almost over and Week 5 seems like a long long time ago. I remember how we took it very slow at first, just tracing recursion on paper before even writing any code. And when we did write code, Professor Heap guided us step by step through the exercises. Because of all this, I now feel more comfortable reading and writing recursive code than I was back then. 

Furthermore, all the extra exercises and lab work I've done then since then has really proved to me the importance of establishing the base case of recursive code. As I read through this slogger's post, I found that we kind of tackle problems in the same way. We feel more comfortable in writing recursive code once we're confident that the function handles the base case correctly.We also try to break down complex problems into smaller pieces by implementing helper functions. I've done this in my Assignments and I find it very helpful especially when debugging code.

Overall, I guess I would have to say that I agree with my earlier post. The difference now is that I've seen more applications of recursion, so I can appreciate it even more. 

Sunday, March 22, 2015

Week 10: Impressions of Week 9

We did not really have much lecture time for week 9 as Term Test 2 occurred during this week. Professor Heap mainly talked more about the Binary Search Tree and its insert and delete method. Deleting a node was a bit more complicated because we had to think about what should happen with the tree depending on whether or not the node had a right child, a left child or both children. This needed to be given some thought in order to preserve the BST condition after deleting a certain node. 

On Wednesday, Term Test 2 proceeded normally even with the strike still going on. Although, I do wish we had our labs back because it's a bit confusing to do the lab exercises without the TA. I think it's been three weeks now since the strike began and I hope it ends soon. 

Saturday, March 14, 2015

Week 9: Impressions of Week 8

When considering to use a certain data structure, we consider its properties and evaluate whether or not it fits our needs. For example, I think of the Binary Search Tree when I think of sorting integers because of its efficiency. I can see its advantages over the list data structure. However, I'm not quite sure when to use Linked Lists. I don't think we've discussed its applications or advantages in class yet. This is something I would like to know more about.

On another note, assignment 2 was also due on week 8. It was definitely more complicated than the first assignment. My partner and I decided to implement the Minimax algorithm first and test it on Subtract Square. Only after finishing that did we move on to implementing the game Tippy. When we finally completed the game, we played a 3x3 board with a computer running Minimax. It always won whenever it made the first move! I felt ecstatic! I was never so happy to lose! It meant the code worked!    

Thursday, March 5, 2015

Week 8: Linked Lists

This week, we set aside recursion for a moment to give way to a new topic: Linked Lists! Basically, a linked list structure is made up of nodes that have a value and a reference to other nodes. The concept of objects (in this case nodes) pointing to other objects was very similar to how Trees worked.

In order to better understand how this data structure worked, I found it really helpful to draw out the nodes and arrows in the proper order. This technique was very helpful when I attempted to do the lab exercises. There were moments when I was really stuck, and drawing the picture bailed me out. By being able to see the linked list structure, I was able to figure out the right sequence in setting or resetting its attributes.

This week was also the first week that TAs went on strike. I understand where they are coming from, and I truly hope an agreement can be reached soon for the benefit of everyone.  

Saturday, February 28, 2015

Week 7

For the past few weeks, we have been focused on writing recursive code. We did several exercise sheets during lectures which I found was very helpful. Furthermore, we were required to write more recursive code during our past two labs. It was very good practice in getting a better understanding of how recursion works, and now I'm more comfortable with it than I was when the concept was first introduced. 

We were also introduced to another abstract data structure: Tree. What I found most especially interesting is not the Tree itself, bu the Binary Search Tree. With this type of data structure, we can easily locate data without having to go through the whole Tree! (This is assuming the BST is relatively balanced) Searching for data thus becomes very efficient since we can easily cut down our search space in half (left or right side of the node) as we find the value that we want.

I would like to be graded on my summary of of object-oriented programming which can be found in in my Week 4 and 6 posts.