Fixed random people switching places and multiplying, and added documentation.