N = int(input()) for i in range(1, N): if (N-i) <= 10: break print("{0} {1}".format(i, N-i))