A group of friends wants to know their average salary such that no individual salary can be deduced. There are at least three friends in the group. How can this problem be solved with a pen and paper?

Sunday, January 20, 2013

Please email your solutions to puzzles@cotpi.com.

### 6 comments

### Credit

This puzzle is taken from folklore.

## Ed Murphy solved this puzzle:

Everyone writes multiple amounts on multiple pieces of paper, one of which is starred and contains his salary plus the sum of all his other amounts. Then all these pieces of paper are mixed up before being opened. The average salary is obtained by subtracting the sum of unstarred amounts from the sum of starred amounts and dividing the difference by the number of friends.

With enough pieces of paper (especially if some of the unstarred amounts are negative), the individual salaries can be made as ambiguous as desired.

## Angela Richardson solved this puzzle:

Each person writes any two numbers (one of which may be negative) that add to his or her salary, each on a different slip of paper. Then the slips of paper are placed in a hat and shuffled. Then they are taken out so that the numbers on them can be added and divided by the number of friends.

## Raul Miller solved this puzzle:

Everyone gets two pieces of paper, and a pen. Everyone writes down two different numbers,one on each piece of paper. These two numbers must average to that person's salary. The papers are all combined into one stack and its values are averaged.

If forensics is a problem, then replace the pen with a suitably anonymous transcription mechanism (for example, wear gloves, and use sheets of adhesive digits to form the numbers).

## Alex Yeilding solved this puzzle:

Each person writes a pseudo-random number between 0.5 and 2 times what he or she thinks the highest paid member of the group might make on a yellow slip of paper. The total of those slips is noted. Everyone draws a slip of paper at random. Each then adds the number he or she draws to his or her own salary, and reveals that number. The total of the numbers revealed minus the total of the random slips is the total pay. The average salary is the total pay divided by the number of friends.

## Devashish Agarwal solved this puzzle:

Suppose there are \(n\) friends. The first person comes up with \((n - 1)\) numbers such that the sum of these numbers is his salary. He writes these numbers on \((n - 1)\) slips of paper (one number on each slip of paper), and distributes them randomly among his friends such that each friend gets one slip of paper. Each friend then adds his salary to the number on the slip of paper received by him. Then they add the \((n - 1)\) numbers thus obtained and divide it by \(n\) to get the average salary.

## Alex Yeilding commented:

The five solutions above, including mine, all suffer from the "ballot box" problem. They all require you to collect (or in the case of my or Devashish's solutions, distribute) data anonymously. For example, in Ed's solution, the data must be collected in a way that prevents you from assigning to any one person his starred number and other numbers.

The classic solutions to this problem get around the ballot box, but work only if the wording of the problem is changed to make the standard that no single person can, without colluding with another person, deduce the salary of any other person. These solutions all require the people to sit in a circle and pass data to the individuals on their right and/or left. In these cases, individuals on either side of a person can compare notes to deduce the salary of the person sitting between them.

Examples: