|go ahead... be a heretic|
Send x% of the users to A, the rest to Bby DreamT (Pilgrim)
|on Oct 26, 2012 at 10:20 UTC||Need Help??|
DreamT has asked for the
wisdom of the Perl Monks concerning the following question:
br> I have a task where i'm supposed to send a certain percentage of the users to one location, and the rest to another location.
I have an idea where I want to use the session key and modulus, but I don't know how to implement it. Some pseudocode:
As you can see I'm quite clueless on this, but it's more of a mathematical problem than a code problem. I know that I need to do some calculations on the string before I can use modulus on it, but how?