Friday, January 30, 2015

Week 4 - Recursion

This week was a long week for me, with many assignments due and most importantly the first assignment on in this course is due on Thursday. I started the assignment very early in this week, and finished all the codes and got it working on Monday, however I wasn't paying enough attention on reading the weight of assignment 1 handout, which made me to miss read that we have to make 5 class part, so instead of writing 5 classes I only wrote 2. I quickly noticed the mistake by the reminder of a friend and added 3 more classes and got them working before Tuesday evening. I worked pretty hard these days on this assignment and got really tired the next day, but still I managed to finish all the doc strings, and due to I was pretty tired I only did minimal amount of testing, and the next day I did lots of testing and handed in on 9:59 PM, just before the deadline.

In this week's class we learned a very interesting programming technique, which is recursion. It is basically used for finding or getting information from lists with many nested lists, like the example below.
(From course note January 26, nested list examples.) 
Recursion can be preformed in a program simply by calling itself in the program. Where we must assume L (in the example above) must either an element of int, or list of elements that satisfies the assumption.

This week's tutorial was very good, the best tutorial I have been to so far in my opinion. The lab handout was easier than the ones before, and it really helped me, step by step to get a good understanding of recursion and was a great practice for writing traces for recursions.

Friday, January 23, 2015

Week 3 - Why should geeks write?

Another new semester started, and not long before I have realized three weeks has already passed. It's only been three weeks of school and I already could not clearly recall what have I done with my precious time in the long summer break. In the other hand when I look back at the Blog I have been posting when I took CSC165, I can suddenly remember all those important things I have learned over the course. Now as the topic asked 'why should geeks write?' This I felt is the main reason why should we write, to continuously gives us chance to refresh our memories burred deep down in us.

In other successful programmer's blog they said that it is also important for us to write clear comments and technical specs for our programs so that other programmers will understand our code. I felt that this is really important aspect of computer programming, due to programs are usually done in a developing group, and having a clear and good communication is the key to success.

It is also very important for us to keep a debugging journal. A debugging journal is very useful for us to record different types of bugs that can occur unexpectedly during programming. Writing a debug journal is really important for helping us to recall different types of bugs, and ways to solve them. I felt that the difference between a good computer programmer and a bad computer programmer really depends on their wisdom and experience on programming, and this is why I felt its really important to write debugging journal.