Arc Forumnew | comments | leaders | submitlogin
3 points by almkglor 5975 days ago | link | parent

Or use this instead: http://arclanguage.com/item?id=7365


1 point by rincewind 5975 days ago | link

the lookup time in alists is O(n). What about proto-tables? Is the key hashed again for lookup in every prototype?

-----

1 point by almkglor 5974 days ago | link

O(M) where M is the depth of the find, or the nested prototype depth if it's not found.

Yes, the key is rehashed.

But really, the point is that proto-tables are quite a bit easier to use: you still retain the table lookup syntax tb.key

-----