n=int(input()) print(1,n-1)if n<11 else print(10,n%10)