#include int main(void){ int N; scanf("%d",&N); if(N<=10)printf("%d %d\n",1,N-1); else printf("%d %d\n",10,N-10); return 0; }