#include using namespace std; #include using namespace atcoder; using mint=modint998244353; //1000000007; using ll=long long; using pp=pair; #define sr string #define vc vector #define fi first #define se second #define rep(i,n) for(int i=0;i<(int)n;i++) #define pb push_back #define all(v) v.begin(),v.end() #define pque priority_queue #define bpc(a) __builtin_popcount(a) int h=100; ll mpow(ll a,ll t){ if(t==0)return 1; ll res=mpow(a,t/2); if(res==-1)return -1; if(res>1e9)return -1; res*=res; if(t&1){ if(res>1e18/a)return -1; res*=a; } return res; } void sol(){ vcmv(h,-1),p(h,1); for(int i=2;i>k; ll wa=0,ac=1e18; while(ac-wa>1){ ll x=(ac+wa)/2; ll kk=1; for(ll i=60;i>=2;i--){ ll l=1,r=1e9+1; while(r-l>1){ ll m=(r+l)/2; ll res=mpow(m,i); if(res==-1||res>x)r=m; else l=m; } kk+=(l-1)*mv[i]; } if(kk>=k)ac=x; else wa=x; } //for(int i=2;i<=24;i++)if(24%i==0)a+=mv[i]; //cout<>t; rep(z,t)sol(); }