Chapter 9 | Sorting and Searching
插入排序,需要调整数组,移位。如果链表好做得多。
9.2 Write a method to sort an array of strings so that all the anagrams are next to each other.
先排一次词本身,再排词之间。
如原解
字典树,自然有序。。红黑树也行。
转换为字典求解。
9.6 Given a matrix in which each row and each column is sorted, write a method to find an element in it.
排除法
背包?