Arc Forumnew | comments | leaders | submitlogin
2 points by akkartik 1048 days ago | link | parent

That Wikipedia page seems to only talk about C++. I just checked and C++'s `map` doesn't support indexing by integer:

So I don't think this is something anybody supports:

  arc> (= grail (otable a "up" b "down"))
  arc> grail.0
Ordered associative containers merely have a well-defined order for iterating over. And the order has nothing to do with the order in which elements were inserted.

So what you're asking for is interesting and plausible, but I don't think "ordered tables" is quite the precise label for it.

2 points by kinnard 1048 days ago | link

Damn. I thought I might've gotten that mixed up. Should've checked.

I think clojure's array-maps do it but with some limitations: