Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

if you need constant time access by index to a sequence of fixed size elements you can use binaries. if you want constant time access to a sequence of fixed size you can use tuples. if you want both you can get close with maps using integer keys or with trees (which i believe are used by clojure behind the scenes for arrays)


If it comes to that I can just use Erlang's implementation but my question is why the omission in Elixir when arrays are supported in Erlang? With Elixir's excellent macro support surely an Elixir wrapper around Erlang's arrays wouldn't be so difficult?


Elixir wrappers that don't significantly enhance what Erlang is already exposing are discouraged within the Elixir community. As I type this, I realize that this might enrage you even more than the lack of arrays ever could. :)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: