//#pragma comment(linker,"/STACK:16777216") /*16Mb*/ #pragma comment(linker,"/STACK:33554432") /*32Mb*/ #ifdef _MSC_VER #define _CRT_SECURE_NO_WARNINGS #endif #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; #define FOR(i,a,b) for (int i = (a); i < (b); i++) #define RFOR(i,b,a) for (int i = (b)-1; i >= (a); i--) #define ITER(it,a) for (__typeof(a.begin()) it = a.begin(); it != a.end(); it++) #define FILL(a,value) memset(a, value, sizeof(a)) #define SZ(a) (int)a.size() #define ALL(a) a.begin(), a.end() #define MP make_pair #define PB push_back typedef long long LL; typedef vector VI; typedef pair PII; const double PI = acos(-1.0); const int INF = 1000 * 1000 * 1000 + 7; const LL LINF = INF * (LL) INF; int val[200]; int n, a; int ans; int pr[200000]; int num[2000000]; int main() { //freopen("in.txt", "r", stdin); //ios::sync_with_stdio(false); cin.tie(0); FOR (i,2,1000) { if (!pr[i]) { for(LL j = i*i; j < 200000; j += i) pr[j] = 1; } } FOR (i,2,200000) { num[i] = num[i-1]; if (!pr[i]) num[i]++; } cin >> a; FOR (i,0,a) { cin >> n; if (num[n] % 2 == 0) cout << "Bob\n"; else cout << "Alice\n"; } return 0; }