• 博客园logo
  • 会员
  • 周边
  • 众包
  • 新闻
  • 博问
  • 闪存
  • 赞助商
  • Chat2DB
    • 搜索
      所有博客
    • 搜索
      当前博客
  • 写随笔 我的博客 短消息 简洁模式
    用户头像
    我的博客 我的园子 账号设置 会员中心 简洁模式 ... 退出登录
    注册 登录
厚积薄发
| 首页 | 新随笔 | 新文章 | 联系 | 订阅 订阅 | 管理

03 2011 档案

 
算法导论(CLRS 2ed) 个人答案 11.2
摘要:题目总体上还是不太难……只是,一个晚上都卡在第四题,做Java实现去了……up date: 最后Java实现了一个上午,终于把第四题做好了。基本思想和Solution Manual是一样的,只是我允许相同key的情况——因为我认为,即使是带着相同的key,data也有可能不同。11.2-1:11.2-2:11.2-3:For everynode, it's a linked list; therefore, by keeping the list sorted, the runningtime would change like this:OperationOriginalNew: k 阅读全文
posted @ 2011-03-09 01:51 songyy 阅读(2204) 评论(3) 推荐(0)
算法导论(CLRS, 2nd) 个人答案 3.2
摘要:感觉挺难的。尤其是3.2-4, 我花了近2h做出来……还是参考了别人的解法的情况下。3.2-1:3.2-2:3.2-3:3.2-4:3.2-5:3.2-6:3.2-7:Reference:Stirling's Approximation, in Wolfman World, retrieved on 2011年3月5日14:35:08, from:http://mathworld.wolfram.com/StirlingsApproximation.htmlCLRS 2e: Exercise 3.2-4, in My Answers. BlogSpot, retrieved at 20 阅读全文
posted @ 2011-03-05 16:53 songyy 阅读(1815) 评论(0) 推荐(0)
算法导论(CLRS, 2nd) 个人答案 3.1
摘要:3.1-1:3.1-2:3.1-3:It's useless because the best case don'tnormally happen.3.1-4:3.1-5:3.1-6: Same as 3.1-5;3.1-7:3.1-8: 阅读全文
posted @ 2011-03-05 14:19 songyy 阅读(562) 评论(0) 推荐(0)
算法导论(CLRS, 2nd) 个人答案 Ch11.1
摘要:11.1-1:Perform a linear search on T, worst case is O(m)11.1-2:0 stands for no elements in the corresponding key, while 1 means the key correspond to some data.11.1-3:Assumption: besides of the key, the satellite data can also have data to be mapped to a secondary key.Thus we can consider a case of 2 阅读全文
posted @ 2011-03-05 12:07 songyy 阅读(1344) 评论(0) 推荐(0)
 

公告


博客园  ©  2004-2025
浙公网安备 33010602011771号 浙ICP备2021040463号-3