I have a question regarding the random function.
In the program I'm building I have a function where a random number is needed
but I also have to repeat the function 3 timesCode:randomnumber = rand() %3 + 1
but when I repeat the function 3 times, the random number in all 3 cases is exact the same
does anyone know how I can avoid this?
ps: I'm using codeblocks and I included time.h for this function