Robert Eisele
Engineer, Systems Architect and DBA

Misc: Three Digits Number

We are looking for a three-digit number that meets the following conditions:

  • The third digit is the product of the first two digits
  • None of the three digits is a prime
  • The number sought is not divisible by any of the numbers 3 to 9

Solution

We are looking for a three-digit number \(x\), that consists of the digits \(a, b, c\). It follows that:

\[100\leq 100a+10b+c<1000\]

Since the third digit is the product of the first two digits, it follows:

\[c = ab < 10\]

Also, let none of the three digits be a prime, so:

\[a,b,c\notin \{2,3,5,7\}\Leftrightarrow a,b,c\in \{0,1,4,6,8,9\}\]

If the number \(x\) shall not be divisible by 5 it follows the last digit \(c\) is not zero or five. Since five is already excluded by the prime rule, we have \(c\neq 0\). Because \(100\leq x<1000\) follows that \(a\) is not zero and from \(c=ab\) follows that \(b\neq 0\). This means \(x\) does not have any zero digits.

The product of the first two digits \(a\) and \(b\) combined with all remaining digits \(\{1,4,6,8,9\}\) shows that \(c<10\) is only possible if \(a=1\) or \(b=1\). The final number \(x=100a + 10b + ab\) can therefore only have the following format: \(100 + 11b\) or \(101a+10\).

Possible solutions are therefore \(x\in\{111, 144, 166, 188, 199, 414, 616, 818, 919\}\).

If we test this set of possible solutions against the given divisibility restrictions, we find the solution to be \(x\in\{166, 199, 818, 919\}\).

« Back to problem overview