#include #include using namespace std; typedef long long ll; int main(){ ll x; cin >> x; ll ans = 1; while(1){ if(x%2 == 0){ x /= 2; if(x%2 == 0){ x /= 2; }else{ ans *= 2; break; } }else{ break; } } ll divisor = 3; while(divisor <= x){ if(x%divisor == 0){ x /= divisor; if(x%divisor == 0){ x /= divisor; }else{ ans *= divisor; } }else{ divisor += 2; } } cout << ans << endl; return 0; }