#include #include #include using namespace std; #define length(array) (sizeof(array) / sizeof(array[0])) int priming(int N, int primes[], int times[]) { int shou = N; int index = 0; int i = 2; if (shou % 2 == 0) { primes[index] = i; times[index] = 0; for (;shou % i == 0;) { times[index]++; shou /= i; } index++; } for (i = 3; i < shou + 1; i += 2) { if (shou % i == 0) { primes[index] = i; times[index] = 0; for (;shou % i == 0;) { times[index]++; shou /= i; } index++; } } return index; } void printints(int list[], int l) { cout << "["; for (int i = 0; i < l; i++) { cout << list[i] << ", "; } cout << "]" << endl; } void copy(int moto[], int saki[], int l) { for (int i = 0; i < l; i++) { saki[i] = moto[i]; } } int judge(int times[], int l, int depth) { if (depth < 0) {return 100;} int sum = 0; for (int i = 0; i < l; i++) { sum += times[i]; } if (sum == 0) {return -1;} int saizen = -1; for (int i = 0; i < l; i++) { int next[l]; copy(times, next, l); for (int j = 0; j < times[i]; j++) { next[i] = j; saizen = max(saizen, -judge(next, l, depth + 1)); } } //cout << "winner: " << saizen << " at "; //printints(times, l); return saizen; } int main(void) { int N; cin >> N; int primes[int(sqrt(N))]; int times[int(sqrt(N))]; int l = priming(N, primes, times); //printints(primes, l); //printints(times, l); //cout << judge(times, l, 0) << endl; int result = judge(times, l, 0); if (result == 1) { cout << "Alice" << endl; } else { cout << "Bob" << endl; } return 0; }