Simple Script to Combine/Seperate Lines of Text

Sean Ross sross at
Mon Jun 9 04:52:16 CEST 2003

Could you describe the algorithm involved in going from

> airncjrlfojqmxirnxplvmndrhqndj ... e (length n) combined with
> qpmgktincirzpwncjftewnchdtecru ... f (length n)


> motnciqaxhfyeklpgmchqicngiehfc ... a (length n)

is there a mapping that takes 'a' and 'q' and produces 'm'? like, perhaps,
    a==1, q==17
    a+q == 1 + 17 == 18 ?

but that would be 'r', so maybe
     (1+17) - 5 == 13 == m
is the formula.
But that doesn't work for the next characters in the string ('i' and 'p'):
    i==9, p==16,
    (i+p) - 5 == 20 == 't' != 'o' == 15

in other words, the reason escapes me as to why the two strings combined
produce the third string you suggest.
If you could describe how you go from one to the other then I'd like to try
to help with the programming details
of implementing your solution.

More information about the Python-list mailing list