jeudi 29 décembre 2016

Any efficient building function in C++/C to fast uniformly sample b entries without replacement from n entries?

It seems that, using shuffle(Index, Index+n, g) before getting the first b entries is still not efficient enough, where Index is a vector/array storing 0 ... (n-1).




Aucun commentaire:

Enregistrer un commentaire