lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On 16-06-23 02:30 AM, Dirk Laurie wrote:
> The moment that you put an upper bound on n, there is no more any
> theoretical distinction between O(1), O(n) and O(n²).

I suppose you mean "when we set <n> to const". Anyway actual execution
time with algorithm O(n^3) may be smaller than for other algorithm O(n)
for some n's (for example, when n <= some_const).