It's almost the same algorithm. The only difference is that the OP's always picks an item from the complete set, whereas Fisher-Yates picks from the set of unassigned items. I don't know if that affects the fairness of the algorithm. It's easy to see that F-Y is fair, but it's hard to see if the OP's is or not. [Upd: After some experimentation, I believe the OP's algorithm isn't fair, and is thus buggy.]
In reply to Re^2: My Perl Obfuscator
by ikegami
in thread My Perl Obfuscator
by harangzsolt33
For: | Use: | ||
& | & | ||
< | < | ||
> | > | ||
[ | [ | ||
] | ] |