# Would I be able to use mathematics to prove properties that would help me solve this series of puzzles?

I realise that this may be a little different from most of the questions you get on math.stackexchange, so for that I apologize. I also apologize if there's no "one right answer" given the way I've phrased this question.

There's a puzzle in the video game Final Fantasy XIII-2 that is colloquially known as the "Hands of Time" puzzle. It's reasonably easy to solve it algorithmically. Right now I try to "think ahead" and that works well on small puzzles but really falls apart on big ones. I'm wondering if there's a way to describe a number of its properties and give concrete advice to a player so they'd be able to quickly and easily solve a given puzzle without resorting to doing the algorithm in their head. In addition, this is something of a mental exercise for me because I'm neither a mathematician (in high school and University I tolerated it but I've never enjoyed it) nor an algorithms person and I'm curious to observe how others reason about puzzles like this one.

Anyway, here's the puzzle.

You have a list of $N$ numbers that are arranged in a circle. When you "activate" a number at position $n \in N$ (let's call that number $g$ since it's basically an array at position $n$), the "two hands of the clock" (minute hand and hour hand) first point to position $n$ but then "spread out" such that they independently point at position $n-g$ and $n+g$, then the number $g$ disappears (if you go above N or below 1 you would wrap around the list, such that $-1$ actually points to $N$, $-2$ points to $N-2$, and so forth). This means that if you're given a number $n = \frac{N}{2}$ and $N$ is even, the hands both point to the opposite size of the clock. It's customary to have the values $g$ be $g \leq \frac{N}{2}$. If both numbers at $g$ at position $n-g$ and $g$ at position $n+g$ are already activated then you lose. The goal of the puzzle is to activate every number in the list $N$.

An example may look like this:

  2
3   2
1   1
2


You're given free reign to select the starting position. If you select the "2" at the 12 o'clock position, the 2 at the 12 o'clock position disappears and the hands then point 2 away at the 1 and the 1. Then you would select the "left" 1, it would disappear, and the hands would point at 3 and 2; you would select 3 and the hands would point at the opposite 1. You select that 1 (only space you can go to) and the hands would go to the 2 at 6 o'clock and on the upper-right. Selecting either of these 2s ensures that you can select the other one, and you would solve the puzzle. If I gave the positions IDs starting at the top going clockwise, it would be 1-2-3-4-5-6 and the solution to this puzzle would be 1-5-6-3-6-2.

There's an online puzzle creator (and solver) and a related Gaming.Stackexchange discussion. If you look up "Hands of Time Final Fantasy XIII-2" you will get some pictures of what the clock looks like in-game.

• How are $n$ and $g$ different? In your description, it sounds like they are the same, so when they spread out they point at $0$ and $2n$. This sounds like a generalization of the Josephus problem I tried the link to the creator and solver, but it didn't do anything. It made the base picture but didn't do more. Commented Mar 14, 2013 at 3:10
• n is the position, like a key, whereas g is a value that's at the the position n. If it was an array $a$ in a programming language then $g = a[n]$, and the array is max size $N$, and g could be different at each position (as long as it's within 1 to $\frac{N}{2}$). I looked at the Josephus problem and it does look similar, except that it goes in both directions rather than in one, and that "empty" spots are not skipped whereas they appear to be in the Josephus problem. Commented Mar 14, 2013 at 3:26
• So if $N=1000, n=73, g=3$ what number(s) disappear? Is one of $n$ or $g$ given as you come to the puzzle? Commented Mar 14, 2013 at 3:43
• The number that disappears would be the 3 at position 73. It is permissible to have multiple values of g throughout the list. I suppose one way to consider it would be that the number at $n=73$ is $g(73)=3$, and selecting $n=73$ sets $g(73)=0$ (if you select a position with 0, obviously nothing happens and you'd lose). Commented Mar 14, 2013 at 4:05
• So we start with an array of length $N$ that holds ints, which are $g(n)$ for $n=0,1,2,\ldots N-1$? I still don't understand what my move is-do I specify $g$, or $n$ or both? Commented Mar 14, 2013 at 4:18