#include using namespace std; #define mp make_pair #define pb push_back typedef long long ll; typedef complex point; typedef pair pii; typedef vector vi; #define DEBUG 0 #define dout if(DEBUG) cout const int MAXN = 1e5 + 5; bool isPrime[MAXN]; int win[MAXN]; void precalc(){ for(int i = 2; i < MAXN; i++) isPrime[i] = 1; for(int i = 2; i < MAXN; i++){ if(!isPrime[i]) continue; for(int j = i + i; j < MAXN; j += i){ isPrime[j] = 0; } } int last = 0; for(int i = 2; i < MAXN; i++){ if(isPrime[i]) last ^= 1; win[i] = last; } } void solve(){ int g; cin >> g; int n; for(int i = 0; i < g; i++){ scanf("%d", &n); if(win[n]) printf("Alice\n"); else printf("Bob\n"); } } int main() { #ifdef NASTYA assert(freopen("input.txt", "r", stdin)); assert(freopen("output.txt", "w", stdout)); #else //assert(freopen(file".in", "r", stdin)); assert(freopen(file".out", "w", stdout)); #endif precalc(); int t = 1; while(t--) { solve(); } return 0; }