djfz-2020-s444344/TaskD00/run
Zofia Bączyk 9f2fe06109 atempt 1
2020-12-02 19:46:14 +01:00

21 lines
503 B
Python

#!/usr/bin/python3
import sys
import re
def fromNumber(m):
m = re.sub(r'0', 'a' , m.group(0))
m = re.sub(r'1', 'b' , m)
m = re.sub(r'2', 'c' , m)
m = re.sub(r'3', 'd' , m)
m = re.sub(r'4', 'e' , m)
m = re.sub(r'5', 'f' , m)
m = re.sub(r'6', 'g' , m)
m = re.sub(r'7', 'h' , m)
m = re.sub(r'8', 'i' , m)
m = re.sub(r'9', 'j' , m)
return str(m)
for line in sys.stdin.readlines():
temp=re.sub(r'\d{4}', fromNumber ,line)
print(temp.strip('\n'))