0

In short I'm looking for a concise algorithm for generating sudorandom numbers in C that I can assign as Integer Values. I would also like to be able to assign a max value limit for generation.

tshepang
  • 12,111
  • 21
  • 91
  • 136
  • Is there any reason [`rand()`](http://linux.die.net/man/3/rand) won't work for you? – Mike Jul 01 '13 at 19:48

1 Answers1

-1

This is a useful function you could use I made!

int getRandomNumber(int max)
{
    Random r = new Random();
    int number = r.Next(0, max);
    return number;
}
La2o
  • 1
  • 1