- Thread starter
- #1

(XXXXXXXX)XXXXXX --> [XXXXX]XXXXXX

(XXXXXXXX)XXX --> [XXXXX]XXX

(XXXXXXXX) --> [XXXXX]

So, you start with 14 X's and end with 5 X's, and the process carried out here can be summarised as '14, 11, 8, 5'. The process that was underwent in terms of finding and replacing can be described as (8,5) as 8 X's are replaced with 5 each time. Now, the question here is:

When you initially have a string of 1,000,000 X's, and apply the find-and-replace process of (99,90), what is the summary of the process here?

By summary of the process, I mean the '14, 11, 8, 5' which shows how many X's are left after each step.

I tried solving this manually, starting the process summary as '1,000,000, 909,091, 826,453, 751,321, 683,020, 620,929, 564,481, 513,172, 466,525' however I realised this was a very inefficient way of solving this, and prone to mistakes. Can anyone help me do it in a better, easier way?

ALSO FOLLOW UP QUESTION

For the (7,3) process, find all start lengths which eventually result in an end length of 6.

I can see 10 being applicable for this, however manual testing every number to find a suitable match is also quite inefficient. If you can help me for this question too, please do. Also, please explain in more simple math terms, rather than using symbols (as I am still a beginner) Thank you!