2013年11月4日星期一
A thin slice of selection sort and quick sort
We spent half of the lecture time on the topic Big O, and after that we moved on to the topic sorting. Sorting is quite interesting to me as it allows us to produce another list with certain order or command. I've learned a little bit of sorting methods in csc108, however, I was really unclear about its idea that time. But in today's lecture, Prof danny brought in a stack of coffee cups and did an interesting demonstration of the selection sort and quick sort with these "tools". I found the idea of selection sort and quick sort salient now. Which selection sort mainly focus on swaps of 2 item and start from beginning, while quick sort saves more time by just randomly extracting one out and do comparison. Both of these sorts gives a rearranged list of the original list. However, the idea of them wasn't fully covered yet because we ran out of time at 10am. Therefore, I believe the idea of sorting will be discussed in a more detail sense in the upcoming lecture.
订阅:
博文评论 (Atom)
没有评论:
发表评论