Sunday, March 8, 2015

Binary search processing...

    Week 7 of the winter term and the 'questionable decisions' are rolling in. First off, I regret, greatly, not spending more of my time during the reading week working on A2 since I realized, figuring out a proper algorithm for checking for tippies, a lot harder than one would imagine. Don't even get me started on minimax. Only time will tell me how well I do on this assignment as that is what I need most right now.

    On the other side of the coin, binary search. The concept of binary search seems like it could be a very powerful tool in many situations, not just to combine elements of mathematical expressions. I would imagine the features that are tied into folders, that we take for granted, are tied into binary search. This weeks lab didn't go as smooth as I would normally expect. I assume it was due to the fact that my previous intuition of recursion is still lacking in some parts. One of the questions asked us to create a method called 'list_longest_path'. I had a hard time figuring out how the algorithm works since I repeatedly questioned how I would search two branches at the same time. and figure out which branch held the longest path. In the end, after asking the TA, I slowly applied an algorithm I assumed would work which lead to a common problem that I have with computer science, which is: 'My code works, but I have no idea why.' The methods afterwards were also challenging as there were many possible outcomes that had to be taken into account, which, again, took me a long time to figure out but in the end, the method only worked for the given example, and not all possibilities. I should probably revisit this lab specifically, again, on a later date. 

 

No comments:

Post a Comment