This one needs a little bit of a bigger explanation: First let me say that I'm aware that this is neither the fastest algorithm nor the best algorithm to represent in funge-space. But its reasonable fast and I liked the challenge of doing such a big program (in terms of raw code size) in befunge. First we take a 4-dimensional cache of all possible number combinations (so an `bool[10][10][10][10]` array) where we remember if a combination is valid. In our program we represent it as an 2D-field with `X=s1*10+s2` and `Y=s4*10+s3`. Initially we set all fields to true where `0 n*C = n*A + n*B ~~~ A little more attention is needed when doint multiplication and division, for the first we have to divide by the factor after the operation and for the second we have to multiply it: ~~~ C = A*B => n*C = (n*A * n*B) / n C = A/B => n*C = ((n*A)*n / (n*B) ~~~ It is important that we multiply the dividend by the factor and not the result of the division, otherwise the decimal places will get lost. As usual a final note from me: Nice problem. 10/10 would solve again