How many solutions does this Numeric puzzle have?

134 Views Asked by At

Numeric puzzle $$\text{Happy} - \text{new} - \text{year} = 2018$$ where each letter corresponds to a single digit. How many solutions does this equation have?

3

There are 3 best solutions below

0
On BEST ANSWER

First letter H=1, then second letter a=0 or 2. If a=0 then y=8 and if a=2 then y=9. So only five variants for "Happy" exist: 10558, 10668, 10778, 10998, 12009. For each of them exist two variants: 10558 - 234 - 8306 = 2018,

10558 - 236 - 8304 = 2018,

10668 - 243 - 8407 = 2018,

10668 - 247 - 8403 = 2018,

10778 - 254 - 8506 = 2018,

10778 - 256 - 8504 = 2018,

10998 - 274 - 8706 = 2018,

10998 - 276 - 8704 = 2018,

12009 - 364 - 9627 = 2018,

12009 - 367 - 9624 = 2018

There are 10 solutions for the puzzle.

0
On

With PARI/GP , I found these $10$ solutions :

? q=0;forvec(z=vector(8,j,[0,9]),if(length(Set(z))==8,[a,e,h,n,p,r,w,y]=z;if(h*n
*y>0,if(h*10000+a*1000+p*100+p*10+y-n*100-10*e-w-y*1000-e*100-a*10-r==2018,q=q+1
;print(q,"   ",z)))))
1   [0, 3, 1, 2, 5, 4, 6, 8]
2   [0, 3, 1, 2, 5, 6, 4, 8]
3   [0, 4, 1, 2, 6, 3, 7, 8]
4   [0, 4, 1, 2, 6, 7, 3, 8]
5   [0, 5, 1, 2, 7, 4, 6, 8]
6   [0, 5, 1, 2, 7, 6, 4, 8]
7   [0, 7, 1, 2, 9, 4, 6, 8]
8   [0, 7, 1, 2, 9, 6, 4, 8]
9   [2, 6, 1, 3, 0, 4, 7, 9]
10   [2, 6, 1, 3, 0, 7, 4, 9]
?
0
On

This is just to record a possibility overlooked by the other answers. If you allow $H=0$, then there is at least one more solution:

$$09117-000-7099=2018$$