《Python Algorithms》的原文摘录

  • In a way, algorithm design can be seen as a way of achieving low asymptotic running time (by designing efficient algorithms), while algorithm engineering is focused on reducing the hidden constants in that asymptotic complexity (查看原文)
    Dantepy 2012-03-13 02:25:37
    —— 引自第20页
  • For timing things, use timeit. (查看原文)
    Dantepy 2012-03-13 02:31:05
    —— 引自第21页
  • 1. Write down the problem. 2. Think real hard. 3. Write down the solution. (查看原文)
    [已注销] 6回复 2012-06-22 23:52:53
    —— 引自第1页
  • 1. Write down the problem. 2. Think real hard. 3. Write down the solution. (查看原文)
    饭团 2012-09-03 11:34:34
    —— 引自第1页
  • >>>def almost_equal(x,y,places=7): return round(abs(x-y),places) == 0 >>> almost_equal(sum(0.1 for i in range(10),1.0) (查看原文)
    freetstar 2012-10-24 11:01:48
    —— 引自第39页
  • For our purposes, a problem is a relation between input and output. (查看原文)
    [已注销] 2018-05-02 11:44:01
    —— 引自第2页
  • where O forms a so-called asymptotic upper bound, Ω forms an asymptotic lower bound. The sets formed by Θ are simply intersections of the other two, that is, Θ(g) = O(g) ∩ Ω(g). (查看原文)
    [已注销] 2018-05-02 11:44:01
    —— 引自第2页