#include<bits/stdc++.h>
using namespace std;
#define int long long
int n,ans,t;
int qpow(int a,int b){
int res=1;
while(b){
if(b&1) res=res*a;
b>>=1;
a=a*a;
}
return res;
}
signed main(){
scanf("%lld",&t);
while(t--){
scanf("%lld",&n);
ans=(long long)log2(n)+2;
if(n-qpow(2,(long long)log2(n))>qpow(2,((long long)log2(n))+1LL)-n) ans++;
printf("%lld\n",ans);
}
return 0;
}
有正确性吗