Why does delete!() work with sets, but not deleteat!()

I can see that. I wonder, though, if we should explicitly spell out the converse in the docstring:

  pop!(collection) -> item

  Remove an item in collection and return it. If collection is an ordered container, the last item is returned.

and add “; for unordered containers, an arbitrary element is returned.”

7 Likes