lua-users home
lua-l archive

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


> Is there a reason why the protocol for `ipairs` has changed from 
> "iterate to first nil value" to "iterate to #table"? The first is well 
> defined for all tables, and runs in O(n), while the second needs 
> O(nlog(n)) time

It's O(n+log(n))=O(n) time.