[Mono-osx] bug in Random

Duane Wandless duane at wandless.net
Mon Jan 19 12:27:13 EST 2009


That is a valid question.  From MSDN, the Random class is a Pseudo-random
number generator:
The random number generation starts from a seed value. If the same seed is
used repeatedly, the same series of numbers is generated.

http://msdn.microsoft.com/en-us/library/system.random.aspx

The value in this is that given a seed will produce the same sequence of
random numbers.  So if the client and server both know the seed then
the algorithm will work correctly on both platforms.


On Mon, Jan 19, 2009 at 12:09 PM, Matt Emson <memsom at interalpha.co.uk>wrote:

> Duane Wandless wrote:
>
>> Maybe I incorrectly assume that the pseudo-random number should be the
>> same on both platforms... but I believe that it should be a predictable
>> sequence given the same seed.
>>
> Maybe this is a silly question, but why would you want your *random* number
> to be the same on both platforms, more so "a predictable sequence"? Sure I'm
> missing something obvious, but... ?!
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-osx/attachments/20090119/dcf9e247/attachment-0001.html 


More information about the Mono-osx mailing list