Like Gabe said, we didn't think this existed elsewhere so we wrote it ourselves. However if this is not the case let us know. Also is our implementation wrong? You seemed a bit unsure when you said "in a completely random fashion".