Remove all elements in an associative array
Jimmy Cao
jcao219 at gmail.com
Fri Jun 24 23:40:11 PDT 2011
On Fri, Jun 24, 2011 at 10:41 PM, Nub Public <nubpublic at gmail.com> wrote:
> Is there a way to remove all elements in an associative array?
>
> I tried clear() but it doesn't work. For some reason it sets the length of
> the array to gibberish. What does clear() do exactly?
>
This same thing was asked many years ago:
http://dsource.org/projects/tutorials/wiki/DeleteAllKeysFromAssocArrayExample
The example is very old and it's for D1.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d-learn/attachments/20110625/e2e4e194/attachment.html>
More information about the Digitalmars-d-learn
mailing list