Gengulphus wrote:UncleEbenezer's answer and mine differ, both with regard to the maximum length of a chain of subtractions to get to the digits 1,4,6,7 and to how many starting states produce a maximum-length chain.
Do they? I haven't read the whole of your post. I note you claim a "chain of length 7", but I don't see one in your post.
If I read you right, you cite 5100 as your first starting number for a chain of length 7. Working through that in my state machine, I get
1/5(6) -> 0/8(5) -> 2/7(4) -> 4/6(3) -> 1/3(2) -> 4/8(1) ->2/6(0)
which looks like six steps.
Aha, got it, your 7 is nodes, my six is steps (actual subtractions).
As for the number of start states, I made no attempt to count them. It wasn't part of the question as I read it!