So I am becoming quite frustrated with how to create a truly, unique random number in a range.
rand() generates the same random sequence, which is just beyond pointless to me.
srand() is far too complex and I don't understand it at all.
std::uniform_real_distribution for some reason just won't work in my IDE (code::blocks for Windows) even when I tell it to use the C++11 standard, but I've seen it work in other implementations of my code on my other computer in Xcode.
Is there any actually simple way to generate a random, unique number in C++?
Aucun commentaire:
Enregistrer un commentaire