From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,248d2a0e5d01f107 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-07-12 15:52:44 PST Path: archiver1.google.com!postnews1.google.com!not-for-mail From: matsw@bluewin.ch (Mats Weber) Newsgroups: comp.lang.ada Subject: Re: Problem with Gnat.Dynamic_Tables Date: 12 Jul 2002 15:52:43 -0700 Organization: http://groups.google.com/ Message-ID: <9c20a68d.0207121452.3ff1eb2f@posting.google.com> References: <3D2B6BFB.D4468F57@easystreet.com> <5ee5b646.0207110713.a6b5a05@posting.google.com> <3D2DEC07.9E47AC3@easystreet.com> <5ee5b646.0207111942.58720e6f@posting.google.com> <3D2E7EBC.C629C700@easystreet.com> <3D2EE650.8070200@bluewin.ch> <3D2F0A3D.8DEF335F@easystreet.com> NNTP-Posting-Host: 128.178.42.73 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Trace: posting.google.com 1026514363 10603 127.0.0.1 (12 Jul 2002 22:52:43 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: 12 Jul 2002 22:52:43 GMT Xref: archiver1.google.com comp.lang.ada:27029 Date: 2002-07-12T22:52:43+00:00 List-Id: achrist@easystreet.com wrote in message news:<3D2F0A3D.8DEF335F@easystreet.com>... > [...] I see that it > works like a Map, which means, I suppose, that there is some search > involved in simply accessing an element of the array, but this is not a > noticeable problem, given all the other inefficiencies in my code, which > hardly add up to anything noticeable in toto. Dynamic_Array is implemented using AVL trees. So there is searching involved for each access and the complexity is O(Log N). But it is a far better choice than an array implementation if your key values are sparse.