15 lines
340 B
Plaintext
15 lines
340 B
Plaintext
|
#!/usr/bin/python3
|
||
|
|
||
|
import sys
|
||
|
import re
|
||
|
|
||
|
for input in sys.stdin.readlines():
|
||
|
answer = re.findall('[0-9]{4}',input)
|
||
|
if answer:
|
||
|
spewuenic = input[:-1]
|
||
|
for num in answer:
|
||
|
spewuenic = re.sub(num, chr(ord(num[0])+49)+chr(ord(num[1])+49)+chr(ord(num[2])+49)+chr(ord(num[3])+49), spewuenic)
|
||
|
print(spewuenic)
|
||
|
else:
|
||
|
print(input[:-1])
|