import re import sys pattern = re.compile(r"[0-9]{2}-[0-9]{3}") for line in sys.stdin: x = re.findall(pattern, line) if x: print(x[0][:2]) else: print("")