Solving the 'insert any number of operators' problem

244 Views Asked by At

I recently came across a rather simple problem: express the number 2008 using thirteen zeroes (yes, zeroes). The solution is, obviously, to use the fact that $0!=1$ and consequently attempt to use up the thirteen 1s to get at the result with the use of brackets, basic operators as well as powers and factorials/double factorials/subfactorials.

Question 1: is it possible to find all solutions to this problem without brute-forcing it? Are there any optimization techniques available for solving this?

Question 2: just curious whether there's other operators or tricks out there to get at the right result.

P.S.: interesting/crazy solutions to this problem are also welcome :)

1

There are 1 best solutions below

2
On

I just randomly guessed a solution:

$((0!+0!+0!)!)!!*(((0!+0!+0!)!)!!-(0!+0!+0!)!)-(0!+0!+0!+0!)!!$

$((1+1+1)!)!!*(((1+1+1)!)!!-(1+1+1)!)-(1+1+1+1)!!$

$(3!)!!*((3!)!!-3!)-4!!$

$6!!*(6!!-6)-8$

$48*(48-6)-8$

$48*42-8$

$2016-8$

$2008$