Saturday 4 April 2015

Week 12: Say it ain't So

CSC 148 Entry 11

     Ahh, here we are again in a familiar position. Similar to last term when I had to write about slogs in 165. It's sad to see that the course is over already. I find that I enjoy all my computer science courses the most. Perhaps, that's why I decided to try and do a specialist. When I look back at the past challenges which I have encountered I do not think they are as hard as they are. That opinion might be biased but it's a valid thought. I feel like I have grown this past semester over this course.

     The big take away in the material I have learned would be recursion and various data structures such as trees, linked lists, binary search trees and a lot of different techniques of implementation. I found that I actually enjoyed all of the assignments. I was sort of disappointed with the last assignment because professor heap originally said that we might implement chess and possibly a chess AI. I was quite intrigued with this challenge.

     The biggest conceptual hurtle I had was wrapping my head around recursion but eventually through the shear amount of problems encountered I am very glad I went through the trials and tribulations to understand recursion. I can really envision me 10 years from now in my office thinking about first year in university. And I would nod to myself and say one word recursion.

Sunday 29 March 2015

Week 11: Back to the Streets Where We Began!!! AGAIN

CSC 148 Entry 10

      In my previous slogs I talked about quite a lot about recursion and I still agree with the opinions which I had previously how powerful a tool recursion is. I think took a less serious tone in my slogs trying to make small jokes and making some pop-culture references. Like the title "Back to the Streets Where We Belong" is actually lyrics in the song Nine in the Afternoon by Panic! I put this as the title originally because of the way recursive functions call on themselves and it reminded me of this song for some reason. Some people I know took a more serous approach to the slogs and had more focuses on the technical aspects of the slogs. 

http://csc148justinsong.blogspot.ca/search?updated-max=2015-02-12T18:02:00-08:00&max-results=7

Personally I sort of wish I took a more serious approach to how I addressed things in slogs similar to my colleagues. However I also do not regret my decision to how I talked about my slogs. I think that the term expression is open enough to warrant different approaches on how to write about it. As for the actual content which I wrote I still agree with what I had to say about recursion. Except now that I have so much experience with recursion I do not have same amazement I had originally of it.

Friday 20 March 2015

Week 10: ...

CSC 148 Entry 9

     I don`t think there was much to reflect on this week besides binary search trees. Due to the test and strike we only had one lecture this week. I do feel very impacted by the strike however since my tutorials were one of my motivations for reviewing the course materials. I feel that because of the strike I have become more lazy and actually spend quite a bit of time not doing much since all my tutorials have been canceled.

     After being shown how to implement insert and delete for the binary search tree I was not as impressed as I was by the other concepts when we encountered them. Although the binary search tree is ordered and is very useful it did not have as big an impression as when I encounter the other concepts. As I have already mentioned in my previous post I feel that did quite well on the test and I am quite at ease.

Saturday 14 March 2015

Week 9: Chooo Chooo, Coming Through!!!

CSC 148 Entry 8

     We learned about linked lists last week. I did not think that linked lists were that difficult and I found it quite intuitive actually. Sort of like a chu chu train. When iterating through this type of data structures as long as several variables are tracked such as what the previous node was doing manipulations of the linked lists isn't as difficult as it seems. It's sorta like playing with toy trains and just combing them in different ways. I find that after I made the visual distinction of train cars being linked to each other I found this concept to be fairly simple.


     I'm somewhat worried about the test when I was studying for it however, after writing the test I was quite confident about my answers. I stuck around a bit at the end and even had a quick chat with professor heap and I found out some of my answers were write and this gave me a very powerful calmness when I was walking back to residence.

I took a look at some various slogs and I was brought to shame when I saw this monster of a post
http://computersciencemaggie.blogspot.ca/2015/03/summary-of-object-oriented-programming.html?showComment=1426384453547

I think this is one of the posts which I actually found useful when to read through. No other posts were developed or expanded on to this extent.

Saturday 7 March 2015

Week 8: And the Plot Thickens.

CSC 148 Entry 7

     The past week I have been focusing very heavily on the second assignment. Minimax was quite challenging to implement and it kept me wondering about what problems we will be given in assignment 3. I think assignment 2 is officially the most challenging formal programming task I have worked on. In other news the TAs are on strike. I completely did not expect this I wonder what will become of labs and whether or not our assignment 2 are even going to be marked. 

     Week 7 had quite a bit of interesting focusing mainly on binary trees which only have two children in the tree. When we were first introduced to the subject I immediately through of binary searching something which encounter in 108 beforehand. Tree traversal was somewhat interesting, the various tree traversal techniques such as in-order traversal, pre-order traversal and post-order traversal. These concepts are as hard to grasp as recursion and I found it pretty simple of just drawing a tree and going through how the various nodes would be visited.

Saturday 28 February 2015

Week 7: Pimp My Function


 CSC 148 Entry 6

     Yo dawg I heard you like to write functions, so I made you a function that calls on itself so you can use the function to iterate through trees and other types of data structures.


     The more I learn about recursion the more I am impressed by the various possible things which can be done with recursion. For example, we learned how to iterate through lists nested in lists. When I originally saw the problem I was thinking of possible convoluted solution to the problem. However, the solution was so simple and elegant.

if isinstance(variable, list):
     return something([funciton(x) for x in variable])

This solution to the problem of iterating through the nested lists seemed so rudimentary yet complex at the same time. It really touched me and and I had a thought that this is what computer science is about coming up with elegant solutions to problems instead of brute forcing them. From then I see recursion in a new light.

     Most of the problems posted in lab 5 and 6 required the use of recursion to solve and this was actually quite challenging to try and solve. The problem was because it was a lot of work and that it required a lot convoluted code to solve; the problem was trying to wrap your mind around the concept of how the function would run over and over again and the possible cases which there are. I found the advice which Professor heap gave in lectures to think of all the different possible cases starting with the base case extremely helpful because it gave me a focus to start off from and eventually solve the problem.

    Although I found the recursive problems very hard, the more problems I see, the more simpler recursion seems. I think this is because all of the solutions to the problems are very similar. You just have to focus on the bases case, accounting for different scenarios and write the recursive step. When working on minimax I found it really helpful to draw diagrams of what is going to happen in each case, I think this is the key to recursion, its not how it will be implemented it's thinking of the conditions for the recursive function. After knowing what to account for the code basically writes itself.

Tuesday 17 February 2015

Week 404 not found: Under the Weather

CSC 148 Entry 5

     Unfortunately after some partying with friends I'm now sick. ): I haven't been this sick all term. I feel sort of thankful though that I'm sick when there's no class.

Friday 13 February 2015

Week 6: A Tangible Object that's Made of 1's and 0's

CSC 148 Entry 4

    Before I talk more about the my understanding of Object-Oriented Programming I thought I think it's sort of poetic having objects exist as an abstract concept within the computer yet existing as nothing more in the physical world as some pattern encrypted onto our computers. So I think it's quite ironic when we call them objects yet it is so fitting.

     Object-Oriented Programming is the creation of classes which in turn dictates the properties which an object of that class has and what can be done with the object. When I first created a class for the first time and understood the implications of what I have done I felt like I was an omniscient being with unlimited power. In my mind I had the thought that I was creating atoms and dictating what physical properties they had and how they could interact with atoms. I think this is an analogy which is quite similar to what is the core concept of Object-Oriented Programming. Classes are like creating an representation of the properties of a type of object. Sort of like dictating the properties of an atom. Atoms are the core components of the world. Everything is made of atoms and different compilations of atoms. Much like how most programs are combinations of classes and how classes interact with each other.


     An instance of a class is defined as an object. Sort of like how matter is all an instance of some atom in the periodic table. Similar to how the periodic table have various groups such as halogens, earth metals, Nobal gases, classes can be under different classes. This is called Inheritance. The classes inherit all the properties of the parent class. Inheritance is something which object-oriented programming has that gives it an extra level of depth. It is essentially the ability to make subsets of objects. This creates a branching of possibilities of types of objects that exist and is very powerful for programming.

Friday 6 February 2015

Week 5: Back to the Streets Where We Began!

CSC 148 Entry 3

     After seeing more of recursion, although sometimes it takes me a quite to trace and understand the code, it's arguably the most useful concept which I have learned this year. After seeing a lot more of it this week, I have a much greater understanding it and how powerful a tool it is. In CSC 165 last semester I learned about time complexity, recursion seems to have a very large big O because of the nature of how recursion works. This was something I was thinking about when recursion was being taught to me. So in my mind I had this mental image of the scene from Spiderman where his grandfather told him that with great power comes great responsibility. However, Instead of it being Spiderman's grandfather it was professor Heap and he as saying with great recursion comes great time complexity. I couldn't help but thing of it having spent so much time on Big O last term with professor Heap. I think I improved a great deal when using recursions from when I first encountered.  them. I think this all comes from how I can trace them a lot easier.

     I dunno how I well I did on the test. I realized after handing in the test that I miss understood the question. I think that it will cost me dearly because the test only has three questions on it. One of my friends in the course expressed concern for the test.

http://sicilliax.blogspot.ca/2015/02/impression-of-first-few-weeks_1.html

However I did not think much about that much about the test because I felt that I had such a great understand of assignment one. I was really confident about the work I did for assignment one that I went into the test with a strange calmness.

Thursday 29 January 2015

Week 4: The First Week of Comp Sci Professor Heap Gave to Me!

CSC 148 Entry 2

     Although I have some previous experience in the field of computer science on my own, 108 and 148 are my first real courses for the field of computer science. Luckily for me python is actually the language which I learned by myself. I am quite comfortable with the material which was displayed the first week in lectures. However the concept of recursion seems like it can give me some trouble since it seems like it can get quite complex quite fast. The first examples shown to us turtle seem quite intuitive and professor heap explained it quite efficient with much swagger. All jokes aside, I have never used the turtle methods before, and that's perhaps the only material in the first week which I am uncomfortable with since I haven't seen it before. I plan to look a bit more into the turtle class on my own so that I am more comfortable with the material which I have encountered.

    I actually really like the first assignment which was given to us. It's something which is quite interesting yet covers the topic which we have very well. I am quite interested in seeing what we have to come up with in the next few assignments since Heap said that the assignments in a way all builds on top of each other.

Thursday 22 January 2015

Week 3: Deja Vu

CSC 148 Entry 1

     Writing on the topic of why geeks should write feels not politically correct because it carries the implication all those who are writing these slogs are geeks which is not necessarily true. Having been through the process of writing these slogs for 165 I am all to familiar with this process. Although I did not find the process to have much merit, I am open to the thought of it helping me. Perhaps I think a better guiding question is should we whether or not it is good to write a blog. During my past experience of writing a blog it felt like an arbitrary activity which I had no real interest in and only participated in because I was being graded on it. Something which I have grown to dislike over the past few years which is being forced to do things not out of general interest of doing them but being forced to do them. However, that's something which is probably inevitable since it's all part of growing up.