Repeatable randomness in Ruby

I know I can "restart" my rand calls by calling srand with a seed, but surely this would affect future calls to rand by other library methods, including cryptographic methods?

How can I repeat my randomness in certain places and still ensure that the rest of my code isn't affected?

5
задан Gareth 29 October 2010 в 16:38
поделиться