djfz-2020-s450026/TaskD04/D04.py

10 lines
238 B
Python
Raw Normal View History

2020-12-06 23:49:28 +01:00
import re
import sys
for line in sys.stdin:
match = re.search(r"(\D*[0-9]+\D+)[0-9]+(.*)", line)
if match:
print(re.sub(r"(\D*[0-9]+\D+)[0-9]+(.*)", r"\1\2", line).rstrip("\n"))
else:
print(line.rstrip("\n"))