Monday, February 17, 2014

CSC148 - Weekly Summary 2/17

Reading week is finally here! Before that, I was spending a lot of time on Assignment 1, the recursion tower of hanoi problem.

We were given an equation to determine the minimum number of moves for moving N number of cheeses from one stool to another. The equation was really hard to solve since there are  more than one variable. We also need to determine what the optimal value for 'i' is for different N values. I wasn't able to find a way to come up with the optimal 'i' value when the assignment is due, however I was able to finish the rest of the assignment.

My solution for the four stools method was able to significantly decrease the number of moves required in comparison to that of the three stools method. My insight was that as long as all four stools were utilized, the number of moves required should decrease. Therefore, I set "i" as (n // 2). The result was as expected and the number of moves required was drastically decreased. However, I realized that it is not the optimal solution and I'm looking forward to hear how my colleagues was able to solve it.

Overall, it was a great learning experience for me, especially from working through the problems alone.

No comments:

Post a Comment