Hello.
I’m generating a list of integers to compute probabilities. Therefore, have a TempGenerator set that holds a bunch of integers, from this list I create many others, getting numbers from it. To be more specific I loop six times and I generate 3 lists that should get unique elements from TempGenerator.
So, in each interaction I get a number x of integers from TempGenerator and set it into a list, after I need to remove those numbers from the set TempGenerator. That’s when things started to get weird. On the first Loop it works using Difference to get a set of number that are in A (TempGenerator) but not in B (TempList) and setting the output into TempGenerator again as shown bellow;
Using the remove items it works perfect!! So, after doing a bunch of tests I couldn’t make sense of what could be wrong. That’s why I think there is some bug on Difference when is used within a loop.