Skip to content

Commit c5ea7a5

Browse files
committed
Append rot13.py
1 parent d9449e8 commit c5ea7a5

1 file changed

Lines changed: 13 additions & 0 deletions

File tree

caesar_code/rot13.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
#!/usr/bin/env python3
2+
# -*- coding: utf-8 -*-
3+
4+
__author__ = 'ipetrash'
5+
6+
7+
def rot13(message):
8+
import codecs
9+
return codecs.encode(message, 'rot13')
10+
11+
12+
assert rot13("test") == "grfg"
13+
assert rot13("Test") == "Grfg"

0 commit comments

Comments
 (0)