I am currently creating a maths game and need a little help.
Inside the Game you can add up coins.
maximum 1 each
(1p,2p,5p,10p,20p,50p,£1,£2)
You can also multiply the current sum
maximum 1 each
(x2,x3,x5)
The total sum of adding coins and multiplying has to equal to a random generated number which is between £10 and £20.(with decimals)
An example: Random Number = £12.22
Answer: [50p] [x2] [£1] [x5] [£2] [20p] [2p]
My Question is: If there is always a solution to a random Generated Number? If the answer is no then what should be the upper-bound
Thank you
I wrote a program to scan the possible plays, and the maximum number of actions (add a coin or multiply) required to reach any value in your playing range is $9$, which occurs only twice at $£16.99$ and $£19.99$
All values up to $£40.00$ are also reachable with no more than $10$ actions. The first value to require all $11$ actions is $£41.99$. The lowest value that cannot be reached is $£59.97$, and $£59.99$ is also unreachable.