- #1

musicgold

- 288

- 13

My question is related to the following puzzle.

“What is the highest number that can’t be created by adding any number of 4s and 9s”?

For example, 25 can be created as follows: 9 + 4 + 4 + 4 + 4 =25

I know that the answer is 23. I also know that the general solution to such a problem, using the numbers X and Y is (X*Y) – X – Y, when X and Y don’t have a GCF. If they have a GCF then, any number that is not divisible by the CGF can not be made using X and Y.

I have two questions.

Q1. How can I derive this formula from scratch : (X*Y) – X – Y ?

Q2. If I am given a number 12345 to figure if it can be created using X and Y, what is the quickest way to do that?

Thanks.