I would like to generate a random floating point number between 2 values. What is the best way to do this in C#?
Here is a snippet of how to get Cryographically safe random numbers: This will fill in the 8 bytes with a crytographically strong sequence of random values.
byte[] salt = new byte[8];
RNGCryptoServiceProvider rng = new RNGCryptoServiceProvider();
rng.GetBytes(salt);
For more details see How Random is your Random??" (inspired by a CodingHorror article on deck shuffling)