On Wednesday, 4 December 2019 at 08:01:59 UTC, Per Nordlöw wrote:
On Tuesday, 3 December 2019 at 13:43:26 UTC, Jan Hönig wrote:
pseudocode:
alias set = bool[]
set foo = ...
set bar = ...
set result;
One simple optimization is to
set* smallest;
set* largest;
if (foo.length < bar.length)
{
On Tuesday, 3 December 2019 at 13:43:26 UTC, Jan Hönig wrote:
pseudocode:
alias set = bool[]
set foo = ...
set bar = ...
set result;
One simple optimization is to
set* smallest;
set* largest;
if (foo.length < bar.length)
{
smallest = &foo;
largest = &bar;
}
else
{
smallest = &bar;
On Tuesday, 3 December 2019 at 18:45:18 UTC, Jan Hönig wrote:
On Tuesday, 3 December 2019 at 13:55:51 UTC, Alex wrote:
This depends on the available accesses on your sets. In terms
of ranges:
Are your sets InputRanges, ForwardRange, ... ?
2) Are there some build-in function for handling su
On Tuesday, 3 December 2019 at 13:55:51 UTC, Alex wrote:
This depends on the available accesses on your sets. In terms
of ranges:
Are your sets InputRanges, ForwardRange, ... ?
2) Are there some build-in function for handling such sets?
This is maybe what you are looking for:
https://dla
On Tuesday, 3 December 2019 at 15:14:03 UTC, ikod wrote:
Never tried, but depending of the nature of your "something"
you can try bit sets. There are efficient algorithms for large
bit arrays (see "roaring" for example).
"roaring" is massive overkill for my case, but thanks for
suggesting i
On Tuesday, 3 December 2019 at 13:43:26 UTC, Jan Hönig wrote:
It seems i don't google the right keywords.
What i want to do: I have two sets. (I didn't find how to do
sets, so i have two associative boolean arrays
`bool[]`). And i want to join them, via an
intersection.
I know how to code t
On Tuesday, 3 December 2019 at 13:43:26 UTC, Jan Hönig wrote:
It seems i don't google the right keywords.
What i want to do: I have two sets. (I didn't find how to do
sets, so i have two associative boolean arrays
`bool[]`). And i want to join them, via an
intersection.
I know how to code t