N=int(input()) x=1 if(N==1): exit(print(0)) while((1<