Qt and random numbers
-
Hi, Qt Developer Network!
My project have to create random "Shultz tables":http://www.st.vstour.info/ShultzTables.html
So it is my first try with qrand() and qsrand().
Can you help me and write howto write a code that will generate random number in diapason 1-25?
Thanks!
<body ></body>
-
-
Sorry for my post into such an old thread, but it must be:
@inline int rangedRand(unsigned int min, unsigned int max){
return (qrand() % (max+1-min)) + min;
}@ -