12
$\begingroup$

ABCD is a 4 digit number where A,B,C and D are 4 distinctly separate digits between 1 and 9.

Using any of the following math operations and the digits A,B,C and D exactly once get the number ABCD.

Math operations allowed: + - x / ^ ! Square root and parenthesis. NO concatenation. There are at least 2 solutions. So answer with the use of the least number of math operations gets the tick.

Please no programming.

$\endgroup$
7
  • 1
    $\begingroup$ To be clear $(4-2)^{10}$ is not allowed? $\endgroup$ Aug 8, 2021 at 13:55
  • 1
    $\begingroup$ The 10 in the exponent is forbidden in capital letters, seems pretty clear. $\endgroup$
    – Bass
    Aug 8, 2021 at 14:07
  • 2
    $\begingroup$ @Bass is correct. Number 10 is not part of 1 to 9 digits. $\endgroup$
    – DrD
    Aug 8, 2021 at 14:13
  • 1
    $\begingroup$ @JaapScherphuis since we're looking for the solution with the least number of operators, it seems unlikely that the factorial and the square root are involved; we need to go from four separate numbers into only one, and unary operations don't change the number of numbers we have. $\endgroup$
    – Bass
    Aug 8, 2021 at 14:36
  • 1
    $\begingroup$ I voted to close this as underspecified to try to prevent it accumulating more and more answers which have different optimal solutions. $\endgroup$
    – bobble
    Aug 9, 2021 at 2:26

6 Answers 6

22
$\begingroup$

On par with Bass, with preservation of digit order:

$5^5=3125\implies(3\times1+2)^5=3125$

Another, this time with reverse digit order:

$(6*1*9)^2=2916$

$\endgroup$
2
  • 3
    $\begingroup$ No, no, this is clearly better than mine, since it preserves the digit order. $\endgroup$
    – Bass
    Aug 8, 2021 at 14:27
  • $\begingroup$ Yes indeed @Daniel Mathias. And I just found a solution with factorials involved. $\endgroup$
    – DrD
    Aug 8, 2021 at 14:32
16
$\begingroup$

In order and very brief

$4096 = 4^{0^9+6}$

... and also illegal since it contains a zero. Thanks @Bass.

If we are allowed parentheses to mean binomial coefficients:

$6435 = \begin{pmatrix}\begin{pmatrix} 6 \\ 4 \end{pmatrix} \\ 3+5 \end{pmatrix}$

$\endgroup$
2
  • 11
    $\begingroup$ This is so beautiful OP should immediately change the rules to lift the ban on zeroes. $\endgroup$
    – Bass
    Aug 8, 2021 at 17:17
  • $\begingroup$ I agree, zero is not evil. $\endgroup$ Aug 8, 2021 at 17:49
10
$\begingroup$

Unless parens count as an operation, this should be optimal:

$(\frac{8}{2}-1)^7 = 2187$

(Of course I'll be keeping an eye out for a solution without parens, and with the digits in the correct order, but that might take a while.)

Here's one without parens, so this is definitely minimal in terms of operations:

$6\times4^5+1 = 6145$

Doesn't have the digit order style points though. After trying pretty much all of the likely candidates, and many unlikely ones too, I'm going to call it: I don't think there is a three operation solution without parens that has the digits in the correct order.

$\endgroup$
3
  • $\begingroup$ Definitely one of the two solutions I had @Bass. I would be interested in knowing how you got there. $\endgroup$
    – DrD
    Aug 8, 2021 at 14:20
  • $\begingroup$ @DrD looked for any x^y with four distinct digits ABCD, then tried to make x and y out of A,B,C and D. Seemed easiest to do any maths while still in single digits. $\endgroup$
    – Bass
    Aug 8, 2021 at 14:24
  • 4
    $\begingroup$ You can get the first in order with a minor modification (2+1^8)^7. $\endgroup$
    – loopy walt
    Aug 8, 2021 at 17:23
3
$\begingroup$

No fancy ordering.

$1296 = 6^{\frac{9-1}{2}}$

$\endgroup$
2
$\begingroup$

How about:

$ 8192 = 2^{{\sqrt{9}}! - 1 + 8} $

Nobody has been using the monadic operations, so I did.

$\endgroup$
1
  • 8
    $\begingroup$ $8^{1+\sqrt 9} \times 2$ is in order and uses fewer operations. $\endgroup$
    – loopy walt
    Aug 9, 2021 at 15:24
2
$\begingroup$

using factorial (!) is a great help to make big numbers using a simple digit num... Based on this, we can find the following answers:

In correct order:

$2163 = (2-1+6!)*3 $

$5167 = 5! + 1 + 6 + 7!$

$4368 = (\sqrt{4}*3)* (6!+8)$

No ordering:

$3625 = (6!+5)*(3+2)$

$5761 =7!+6!+1^5$

$\endgroup$
1
  • $\begingroup$ These do use more math operations then the minimum, so they are not optimal, and optimal solutions have already been posted $\endgroup$
    – bobble
    Aug 13, 2021 at 13:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.