摘要: 入程序员这一行不久,而且是从网络工程师半路转过来的。听说不懂算法的都不能算是合格的程序员,马上开始学算法。今天第一天,加油。看《Introduction to Algorithms》第三版 chapter 2 :插入算法书中的伪代码:for j == 2 to A.length key = A[j] i = j - 1 while i > 0 and A[j] > key A[i+1] = A[i] i = i -1 A[i+1] = key python :A = [1,2,4,3,10,5,7,6]for i in xrange(1... 阅读全文
posted @ 2012-11-22 17:59 notewo 阅读(159) 评论(0) 推荐(0) 编辑