So at the coop I'm living in we pick which rooms we get based on house seniority, determined by how long you've lived in the house in semesters. Unfortunately this leads to a lot of ties and a need for lots of tie breakers. We use Rock-Paper-Scissors most often, which usually works well enough for seeing who "wins". Unfortunately when you have a 5 way tie things get a little hairy so I devised a recursive algorithm to handle the sorts. We'd play round robin RPS which would break us up into buckets of number of wins, more wins meaning more senior. Ties for numbers of wins would be dealt with by the same algorithm (hence recursion). Best case number of matches is (n2-n)/2 (n=number of contestants), assuming that no one ties for number of wins. Course since we had 5 people I noticed that it was possible that everyone get the same number of wins, in which case the problem wouldn't get any smaller and allowing an (unlikely) chance for infinite recursion, which is our worst case scenario. For everyone to have the same number of wins, obviously everyone needs to have the same number of losses as well, though I don't think wins necessarily equals losses. At first I thought this can possibly happen if (n2-n)/2 is even but not on odds. This led me to discover the interesting behavior of that expression in that the change between n's that give you even values alternates between 1 and 3 (ie they are 4,5,8,9,12,13,16,17...). Unfortunately when n=4 (n2-n)/2=6 you cannot have a complete tie. So my next guess would be when n is odd you get a possibility of a complete tie because with n-1 matches per person it is an even count of matches, meaning that it is possible to have wins == losses. Didn't think there was necessarily a connection at first but it seems totally obvious now: total wins and total losses during a set need to be equal just because that's how RPS works, and if we're assuming that everyone has the same number of wins, they'd need to have the same number of losses, and if the two values weren't equal then you'd get the total values not being equal, which can't happen since you can only win or lose RPS (toss out ties, which now that I think about it throws a wrench in here since happens pretty often). Anyway, point is that you should make sure to use a game that has more outcomes than people to determine rank. Otherwise you'd be better off picking some random quality to sort by, like first name.