# The 'Unlock All Digits' Game

I challenged myself and thought of a new problem I tried to solve. Here are the rules :

• The goal is to 'unlock' all the numbers $0,1,2,3,4,5,6,7,8$ and $9$
• When you start the game, the only number to be unlocked is $0$
• To unlock a number, you must express it as the result of an operation between two numbers you already unlocked
• The set of allowed operation between two unlocked number $a$ and $b$ is : $a+b$, $a-b$, $a*b$, $a/b$, $a^b$, $log_{(a)}b$, $\sqrt[a]{b}$, $S(a) = a+1$ and $P(a) = a-1$
• You can use each operation only once.

Here's an example :

$0$ is unlocked

$S(0) = 1$ is unlocked

$1+1 = 2$ is unlocked

$2*2 = 4$ is unlocked

$4-1 = 3$ is unlocked

$3^2 = 9$ is unlocked

$P(9) = 8$ is unlocked

In this example the digits unlocked are : $0,1,2,3,4,8,9$.

My question is : Is it possible to unlock all digits with these rules ?

If you have interesting and solvable variants in mind, I would be pleased to hear about it.

EDIT : There is no solutions. But if you replace the initially unlocked $0$ by another digit, you will be able to find solutions for digits $4,5,6,7,8,9$.

• I think you mean $P(a)=a-1$. This belongs on puzzling.se – Ross Millikan Dec 11 '14 at 18:39
• One of the rules: You can use each operation only once. – Tacet Dec 11 '14 at 18:40
• I agree with Ross that this question would have definitely been welcome on Puzzling.SE. I'm not active on Math.SE, so I'm not sure whether this question is on-topic or not. (I personally like it and upvoted it.) – Kevin Dec 11 '14 at 22:49
• Speaking as someone who frequently frequents Math.SE and far too infrequently frequents Puzzling.SE, my personal opinion is the puzzling site 'needs it' more but that it's fairly appropriate for either location. – Steven Stadnicki Dec 11 '14 at 23:18

No. Since you have as many operations as digits, you must use each operation once and only once, which means all operands must also be digits. But the only numbers expressible as roots (of the form $\sqrt[a]{b}$ (for $a\gt 1$, otherwise nothing new is gained) are $2$ and $3$, and likewise the only numbers expressible as logs are $0$, $1$, $2$ and $3$. Now, from just $\{0\}$ the only number that's accessible is $1$ and from $\{0,1\}$ the only number that's accessible is $2$; and you can't get to $1$ from $\{0\}$ using $\log$, and you can't get to $2$ from $\{0,1\}$ using $\sqrt{}$ or $\log$. This leaves you without enough operations left over for the rest of the digits.
Note that it's possible to complete the chain starting from other digits. For instance, from $9$ one can go $\log_9(9)=1$, $S(1)=2$, $\sqrt{9}=3$, $2^3=8$, $\frac82=4$, $4+1=5$, $2\cdot 3=6$, $P(8)=7$, $7-7=0$.
• Thank you. Before closing the question, I want to ask you another one : if we change the first unlocked digit (here it's $0$), is the game possible ? – Pyrofoux Dec 11 '14 at 18:53
• @Pyrofoux I'll be interested to see what you learn! I suspect several elements of this ($\log_n(n)=1$ as the first step, and $8/2=4$ to use divide, for instance) must be locked in stone but there's certainly some flexibility in some of the operations. – Steven Stadnicki Dec 11 '14 at 22:22
• I checked, and it looks like that there is a lot of solutions for every digit $> 3$ but none for $0$,$1$,$2$,and $3$. – Pyrofoux Dec 13 '14 at 21:58