n = int(input()) for i in range(1, 11): if 1 <= n - i <= 10: print(i, n - i) break