#!/bin/python3 import sys import math def calculate(n): calc = 0 for num in range(2,n+1): done = False for i in range(2, int(math.sqrt(num))+1): if (num % i) == 0: done = True break if not done: calc += 1 return calc g = int(input().strip()) for a0 in range(g): n = int(input().strip()) print("Bob" if calculate(n) % 2 == 0 else "Alice")