Associative Array with double[][]

frame frame86 at live.com
Thu Jul 22 04:46:13 UTC 2021


On Thursday, 22 July 2021 at 03:13:14 UTC, seany wrote:

> If there are multiple possibilities, what is the fastest in 
> terms of memory? Thank you.

I believe the fastest way (as seen from your loop) would be using 
pointer arithmetric and using void* keys for diagonalLengths and 
an index function that is able to pick the void* key/address from 
the given double coordinates.

You may also consider using a binary tree data structure instead 
of AA.


More information about the Digitalmars-d-learn mailing list