Ponder This Challenge - February 2026 - Blot-avoiding backgammon strategy
- Ponder This
Ponder This Challenge:
Let π be a permutation on 14 elements. Define Ni as the minimal number of times the permutation π should be applied to get i back into its original place. What is the remainder, modulo 1299, of the sum over all possible 14! permutations of 4 to the power of the product of (2+the parity of Ni)? I.e, what is
As we will show in the solution, it can be computed almost on the back an envelope.
Update (06/01): Note that a fixed point (i -=> i) is considered odd (Ni=1, parity=1), and a transposition (i -=> j -=> i) is considered even (Ni=2, parity=0).
We will post the names of those who submit a correct, original solution! If you don't want your name posted then please include such a statement in your submission!
We invite visitors to our website to submit an elegant solution. Send your submission to the ponder@il.ibm.com.
If you have any problems you think we might enjoy, please send them in. All replies should be sent to: ponder@il.ibm.com
2+mod(Ni,2) is 2 for i in an even length cycle and 3 for i in an odd length cycle. Since 14 is even, there are an even number of elements in odd cycles and an even number of elements in even length cycles. So the product is:
Since 1299 divides 436-1, the remainder modulo 1299 of 4x depends only on x modulo 36. So
Since the number of permutations with only odd cycles is the same as the number of permutations with only even cycles (Thanks to Vladeta Jovovic for suggesting this equality and to Eytan Sayag for the elegant proof) we have 256+1045 = 2 (mod 1299) from each pair so all together we get the sum of 14! (mod 1299) = 648.
Proving the equivalence between permutation of odd-only cycles and even-only cycles can be shown by writing the first in canonical form (sorting each cycle to start with the biggest element and sorting the cycles by their first element in descending order); then pairing them (if n is even, the number of odd-cycles should be even) and moving the last value from the second cycle of each pair after the last value of the first cycle in the pair. It is easy to show that this transformation is one-to-one from permutation with odd-only cycles to permutation with even-only cycles.