Skip to content

Instantly share code, notes, and snippets.

@KatUser
Created July 18, 2020 02:00
Show Gist options
  • Save KatUser/8ac603f3775331e6f7f2de2c9092ab0f to your computer and use it in GitHub Desktop.
Save KatUser/8ac603f3775331e6f7f2de2c9092ab0f to your computer and use it in GitHub Desktop.
Ceasar_code_ru
rus_alphabet = [x for x in range(ord('а'), ord('я') + 1)]
n = int(input())
s = 'Блажен, кто верует, тепло ему на свете!'
for i in s:
if ord(i.lower()) in rus_alphabet:
print((chr(ord(i)+n)),end ='')
else:
print(i, end='')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment