# Are there any solutions to this logic (?) problem involving modular arithmetic?

Asked by PhiNotPi (12601) April 3rd, 2012

There are 10 people in a group, numbered 0–9. Each person draws an integer 0–9 from a hat without replacement. Each person adds their assigned number to the number that they drew from the hat, modulo 10, in order to get a new number 0–9. When they compare their results, they realize that no two people obtained the same number.

Who drew what number from the hat? Are there multiple solutions or no solutions at all?

As an expanded version of this problem, there can be any (natural) number of people in the group, and all of the number ranges are changed to fit the new group size. Is there ever a solution to this problem?

Observing members: 0 Composing members: 0

this has multiple answers that are possible.

DrBill (16036)

When N is a prime there are multiple solutions. (Run through permutations of N)

RazorsEdge (30)

Are there any solutions for N=10?

@RazorsEdge Not necessarily, at least for N=2. EDIT, I apologize, this is true for primes 3 and above.

PhiNotPi (12601)

Zero solutions for any non-prime.

RazorsEdge (30)

@RazorsEdge I suspect that you’re right, but how do you know?

PhiNotPi (12601)

This has to go in the record books for the fastest I have ever gotten a response. Oh well, I’ll try again tomorrow with a harder question. (:

PhiNotPi (12601)

Because primes are so easy and a a few composites have no solutions… generalize.
I just found this site by accident. lol

RazorsEdge (30)

or