Text decryption P71082


Statement
 

pdf   zip

thehtml

A simple yet unknown mathematical method X was used to encrypt texts made up of only lower-case letters, upper-case letters, spaces and punctuation characters. For every such text ‍t, denote by X(t) the result of encrypting t with X. It is known that for two texts t1t2, X(t1) ≠ X(t2).



Write a program to decrypt a text that was encrypted with X. Deduce X from the sample input and the sample output below.

Input

Input consists of one text encrypted with X, that is, X(t). It has at most 1000 lines, each one with at most 1000 characters.

Output

Print the text such that, once encrypted, produced X(t), that is, the original text t.

Public test cases
  • Input

    Zrm ddsqthn kvr oechxp sm Rneweo ekeuo,
    Jxh srb phifbf rfsq gkndh clf sfe,
    Tqm osqu zzgfsmau yv cnku json xqu ryrx
    Ye deq earigwwqo Okxzrnp Kef.
    
    Vld wdv abce jhhbb aujqt, wjxqetd ydljxwau da gdbkli
    Rr wdv prolplrrv Bdwecem Hnu;
    Oqz kvr gkwue kouua vjsf, fdj J pbqo pys ofzckf bidi
    Lb kvr pvwxffptb Rroaciu Vdo;
    Eer fc, rho feo myplu-tjhn, S ksb prse pl hya vuao
    Xt zm uwuxfxf--ch hbrmmww--li iuia rbq ap xuuao,
    Ua hya vqmeksqvf tiiau ai qth ovo,
    Vb yau flwa rh xie tsddcsks var.
    

    Output

    And neither the angels in Heaven above,
    Nor the demons down under the sea,
    Can ever dissever my soul from the soul
    Of the beautiful Annabel Lee.
    
    For the moon never beams, without bringing me dreams
    Of the beautiful Annabel Lee;
    And the stars never rise, but I feel the bright eyes
    Of the beautiful Annabel Lee;
    And so, all the night-tide, I lie down by the side
    Of my darling--my darling--my life and my bride,
    In the sepulchre there by the sea,
    In her tomb by the sounding sea.
    
  • Information
    Author
    Salvador Roura
    Language
    English
    Official solutions
    C++
    User solutions
    C++