CST 370 Algorithm - Week 5
This week, there are many new algorithms being introduced: Quick Sort, Decrease and Conquer, Topological Sorting, Kahn Algorithm. However, the beauty of these knowledges is in the connection with other aspects.
First of all, when the Professor compared the runtime of regular computer and supercomputer, I can see the importance of algorithms. Moreover, it reminds me of how many application developers, website developers and game developers tend to forget about this important element. They expect the majority, if not all, of their customers to have powerful computers that can run everything with ease. As the result, many applications are downgraded, barely run above average because the developers ignore the performance / optimization entirely.
Second, one example from Professor about the categories in the phone book or dictionary. It is a beautiful example showing that "speed is important, but it's not the primary key" for many real-life situations. We can use Binary Search to make the algorithm run faster, but it doesn't work well in a dictionary. When searching in a dictionary, we go to the first letter, or the category, before search the next letter. That is the Brute Force searching, and that is convenient over speed.
In my own Capstone Project that I am working on, there are many situations where I have no choice but to use the Brute Force Searching. But to make the algorithm runs faster, pre-requisition is needed. In fact, I usually divided them into categorized data structures. So, when searching, I can save time by jumping into corrected data structure based on their categories.
One example from my Project, splitting resources into different lists based on their categories.
Comments
Post a Comment