|From:||José Abílio Matos|
|Subject:||Re: associative array|
|Date:||Thu, 26 Mar 2020 20:25:43 +0000|
On Thursday, 26 March 2020 20.00.39 WET Francesco Potortì wrote:
> I need an associative array, and I tried with structs, with the field
> names as keys.
> Unfortunately it clearly slows down with size. I have about 30000 keys,
> for each I first check if it's already there, if not I create it, if
> it's there I add some data. The number of operations (insertion +
> updates) is around 55000. The slowdown appears to be quadratic (but I
> have not made any measurement, in fact).
> Are there more efficient ways to build and update an associative array?
How about containers.Map:
|[Prev in Thread]||Current Thread||[Next in Thread]|