Assosiative array pop
Meta via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Thu Jun 26 08:58:17 PDT 2014
On Thursday, 26 June 2014 at 09:21:28 UTC, seany wrote:
> On Wednesday, 25 June 2014 at 14:17:50 UTC, Meta wrote:
>
>> If you want something like a hash table that preserves
>> insertion order, you could try using an array of tuples
>> instead. Then to "pop" the first element, just do 'arr =
>> arr[1..$]'.
>
> Thank you, this is _exactly_ what I was looking for! Thank you
> so
> much!
Keep in mind that it will be up to you to ensure that each value
only exists in the array once.
More information about the Digitalmars-d-learn
mailing list