#K89362. Taco Cipher Decryption

    ID: 37514 Type: Default 1000ms 256MiB

Taco Cipher Decryption

Taco Cipher Decryption

In this problem, you are given an encoded message that was encrypted using a simple Caesar cipher with a right shift. Your task is to decrypt the message by shifting each letter backwards by the given shift value.

The decryption process for each alphabetic character is defined by the formula: ( c = (c - \text{shift}) \mod 26 ), where ( c ) represents the position of the letter in the alphabet. Non-alphabetic characters (such as spaces and punctuation) should remain unchanged.

For example, decrypting the string Bcd Efg with a shift of 1 yields Abc Def.

inputFormat

The input consists of two lines. The first line contains the encoded message (a string which may include spaces and punctuation). The second line contains an integer representing the shift value used for encryption.

outputFormat

Output the decrypted message as a single string.## sample

Bcd Efg
1
Abc Def