#include using namespace std; int main() { int p,b=0; scanf("%d",&p); for(int i=2; i<=p/2; i++) { if(p%i==0) { printf("%d",p/i); return 0; } } }