我是正常蛇

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

2012年8月29日

摘要: AlgorithmRunning time:A algorithm's running time depends on a lot of things,such as:Input itself.If the input is already sorted,then the algorithm may have very little work to do.Size of the input.Some algorithms are better at sorting small data while some others are better at large data.Normall 阅读全文
posted @ 2012-08-29 17:59 我是正常蛇 阅读(388) 评论(0) 推荐(0) 编辑

摘要: O:f(n) = O(g(n)) , means that there are some suitable constants,such that 0 <= f(n) <= c·g(n). Consider as less than or equal to.Ex:f(n) = n3 +O(n2) , means that f(n) is basically n3but there are these lower order terms that are O(n2).n2 + O(n) =O(n2)Ω:f(n) =Ω(g(n)) , means that f(n) is a 阅读全文
posted @ 2012-08-29 17:58 我是正常蛇 阅读(199) 评论(0) 推荐(0) 编辑