#include <bits/stdc++.h>
const int maxn = 1 << 20;
using std::cin;
using std::cout;
int is[maxn], can[maxn];
int n, f;
std::vector<int> vec;
int sg[maxn], notsure[maxn];
namespace poly {
const int maxn = 1 << 20;
const int mod = 7340033;
inline long long pow(long long a, int b, long long ans = 1) {
  for (; b; b >>= 1, a = a * a % mod)
    if (b & 1) ans = ans * a % mod;
  return ans;
}
inline long long inverse(long long x) { return pow(x, mod - 2); }
int wn[maxn], rev[maxn << 1], inv[maxn], lim, invlim;
unsigned iwn[maxn];
inline unsigned getinv(unsigned x) { return ((u64)x << 32) / mod; }
inline void init_(int n) {
  int N = 1;
  for (; N < n;) N <<= 1;
  for (int i = 1; i < N; i <<= 1) {
    const int w = pow(3, mod / i / 2);
    wn[i] = 1;
    iwn[i] = getinv(wn[i]);
    for (int j = 1; j < i; ++j) {
      wn[i + j] = (long long)wn[i + j - 1] * w % mod;
      iwn[i + j] = getinv(wn[i + j]);
    }
  }
  for (int i = 1; i <= N; i <<= 1) {
    for (int j = 1; j < i; ++j)
      rev[i + j] = rev[i + (j >> 1)] >> 1 | j % 2 * i / 2;
  }
}
inline void init(int len) {
  lim = len;
  invlim = mod - (mod - 1) / lim;
}
inline void reduce(int& x) { x += x >> 31 & mod; }
static unsigned t[maxn];
inline void fft(int* a, int type) {
  for (int i = 0; i < lim; ++i) t[i] = a[rev[lim + i]];
  for (int i = 1; i < lim; i <<= 1) {
    if (i == 1) {
      for (int j = 0; j < lim; j += 8) {
        {
          const unsigned x =
              wn[1 + 0] * t[1 + j + 0] -
              unsigned((u64)iwn[1 + 0] * t[1 + j + 0] >> 32) * mod;
          t[1 + j + 0] = t[j + 0] + mod + mod - x, t[j + 0] += x;
        };
        {
          const unsigned x =
              wn[1 + 0] * t[1 + j + 2 + 0] -
              unsigned((u64)iwn[1 + 0] * t[1 + j + 2 + 0] >> 32) * mod;
          t[1 + j + 2 + 0] = t[j + 2 + 0] + mod + mod - x, t[j + 2 + 0] += x;
        };
        {
          const unsigned x =
              wn[1 + 0] * t[1 + j + 4 + 0] -
              unsigned((u64)iwn[1 + 0] * t[1 + j + 4 + 0] >> 32) * mod;
          t[1 + j + 4 + 0] = t[j + 4 + 0] + mod + mod - x, t[j + 4 + 0] += x;
        };
        {
          const unsigned x =
              wn[1 + 0] * t[1 + j + 6 + 0] -
              unsigned((u64)iwn[1 + 0] * t[1 + j + 6 + 0] >> 32) * mod;
          t[1 + j + 6 + 0] = t[j + 6 + 0] + mod + mod - x, t[j + 6 + 0] += x;
        };
      }
    } else if (i == 2) {
      for (int j = 0; j < lim; j += 8) {
        {
          const unsigned x =
              wn[2 + 0] * t[2 + j + 0] -
              unsigned((u64)iwn[2 + 0] * t[2 + j + 0] >> 32) * mod;
          t[2 + j + 0] = t[j + 0] + mod + mod - x, t[j + 0] += x;
        };
        {
          const unsigned x =
              wn[2 + 1] * t[2 + j + 1] -
              unsigned((u64)iwn[2 + 1] * t[2 + j + 1] >> 32) * mod;
          t[2 + j + 1] = t[j + 1] + mod + mod - x, t[j + 1] += x;
        };
        {
          const unsigned x =
              wn[2 + 0] * t[2 + j + 4 + 0] -
              unsigned((u64)iwn[2 + 0] * t[2 + j + 4 + 0] >> 32) * mod;
          t[2 + j + 4 + 0] = t[j + 4 + 0] + mod + mod - x, t[j + 4 + 0] += x;
        };
        {
          const unsigned x =
              wn[2 + 1] * t[2 + j + 4 + 1] -
              unsigned((u64)iwn[2 + 1] * t[2 + j + 4 + 1] >> 32) * mod;
          t[2 + j + 4 + 1] = t[j + 4 + 1] + mod + mod - x, t[j + 4 + 1] += x;
        };
      }
    } else {
      for (int j = 0; j < lim; j += i + i)
        for (int k = 0; k < i; k += 4) {
          {
            const unsigned x =
                wn[i + k + 0] * t[i + j + k + 0] -
                unsigned((u64)iwn[i + k + 0] * t[i + j + k + 0] >> 32) * mod;
            t[i + j + k + 0] = t[j + k + 0] + mod + mod - x, t[j + k + 0] += x;
          };
          {
            const unsigned x =
                wn[i + k + 1] * t[i + j + k + 1] -
                unsigned((u64)iwn[i + k + 1] * t[i + j + k + 1] >> 32) * mod;
            t[i + j + k + 1] = t[j + k + 1] + mod + mod - x, t[j + k + 1] += x;
          };
          {
            const unsigned x =
                wn[i + k + 2] * t[i + j + k + 2] -
                unsigned((u64)iwn[i + k + 2] * t[i + j + k + 2] >> 32) * mod;
            t[i + j + k + 2] = t[j + k + 2] + mod + mod - x, t[j + k + 2] += x;
          };
          {
            const unsigned x =
                wn[i + k + 3] * t[i + j + k + 3] -
                unsigned((u64)iwn[i + k + 3] * t[i + j + k + 3] >> 32) * mod;
            t[i + j + k + 3] = t[j + k + 3] + mod + mod - x, t[j + k + 3] += x;
          };
        }
    }
  }
  if (type == 1) {
    for (int i = 0; i < lim; ++i) a[i] = t[i] % mod;
  }
  if (type == 0) {
    a[0] = (u64)t[0] * invlim % mod;
    for (int i = 1; i < lim; ++i) a[i] = (u64)t[lim - i] * invlim % mod;
  }
}
inline void fill(int* a, const int* b, int len) {
  memcpy(a, b, len << 2), memset(a + len, 0, lim - len << 2);
}
typedef std::function<int(int, int*)> fc;
struct solver {
  static const int C = 64;
  static const int B = 32;
  int n, N;
  int rem[maxn], g[maxn], *MM;
  int M[B][(maxn << 1) / B];
  u64 g0[maxn << 2];
  inline void Init(int len, int* multi) {
    MM = multi;
    for (n = len, N = 1; N < len; N <<= 1)
      ;
    for (int mid = (N + N) / B; mid > 1; mid /= B) {
      init(mid);
      for (int j = 0; j + 1 < B; ++j) {
        if (j * mid / 2 < n) {
          for (int i = 0; i < mid; ++i) M[j][mid + i] = MM[i + j * mid / 2];
          fft(M[j] + mid, 1);
        }
      }
    }
  }
  inline void solve(int l, int r, u64* g0, const fc& xxx) {
    if (r - l < C) {
      for (int i = l; i < r; ++i) {
        int j = l;
        u64 x = rem[i];
        for (; j + 15 < i; j += 16) {
          x = (x + (u64)g[j + 0] * MM[i - j - 0] +
               (u64)g[j + 1] * MM[i - j - 1] + (u64)g[j + 2] * MM[i - j - 2] +
               (u64)g[j + 3] * MM[i - j - 3] + (u64)g[j + 4] * MM[i - j - 4] +
               (u64)g[j + 5] * MM[i - j - 5] + (u64)g[j + 6] * MM[i - j - 6] +
               (u64)g[j + 7] * MM[i - j - 7] + (u64)g[j + 8] * MM[i - j - 8] +
               (u64)g[j + 9] * MM[i - j - 9] + (u64)g[j + 10] * MM[i - j - 10] +
               (u64)g[j + 11] * MM[i - j - 11] +
               (u64)g[j + 12] * MM[i - j - 12] +
               (u64)g[j + 13] * MM[i - j - 13] +
               (u64)g[j + 14] * MM[i - j - 14] +
               (u64)g[j + 15] * MM[i - j - 15]) %
              mod;
        }
        if (j != i) {
          for (; j < i; ++j) x += (u64)g[j + 0] * MM[i - j - 0];
          x %= mod;
        }
        rem[i] = x;
        g[i] = xxx(i, rem + i);
      }
      return;
    }
    const int DT = (r - l) / B;
    if (l) memset(g0, 0, r - l << 4);
    int end = 0;
    for (; end < B && l + end * DT < n; ++end)
      ;
    for (int i = 0; i < end; ++i) {
      int L = l + i * DT, R = L + DT;
      if (std::find(notsure + L, notsure + R, 1) == notsure + R) continue;
      if (i) {
        static int T[maxn];
        init(DT + DT);
        for (int j = 0; j < lim; ++j) T[j] = g0[2 * i * DT + j] % mod;
        fft(T, 2);
        for (int j = L; j < R; ++j)
          rem[j] = (rem[j] + (long long)invlim * t[lim - j + L - DT]) % mod;
      }
      solve(L, R, g0 + (r - l << 1), xxx);
      if (i != end - 1 && std::find_if(g + L, g + R, [](unsigned x) -> bool {
                            return x;
                          }) != g + R) {
        init(DT + DT);
        static int b[maxn];
        fill(b, g + L, R - L), fft(b, 1);
        for (int j = i + 1; j < end; ++j) {
          unsigned long long u64, *g1 = g0 + lim * j;
          for (int k = 0; k < lim; ++k) {
            g1[k] += (long long)b[k] * M[j - i - 1][lim + k];
          }
        }
      }
    }
  }
  inline void solve(fc x) { solve(0, N, g0, x); }
};
}  // namespace poly
poly::solver solver, dak;
inline void init() {
  const int n = 2e5;
  poly::init_(1 << 20);
  for (int i = 2; i <= n; ++i)
    if (!is[i]) {
      for (int j = i + i; j <= n; j += i) {
        is[j] = 1;
      }
    }
  for (int i = 2; i <= n; ++i)
    if (!is[i]) {
      can[i] = 1;
      for (int j = 2; j * i <= n; ++j)
        if (!is[j]) {
          can[i * j] = 1;
        }
    }
  dak.Init(n, can);
  for (int i = 0; i < n; ++i) {
    sg[i] = -1;
  }
  for (int i = 0;; ++i) {
    solver = dak;
    int any = 0;
    for (int i = 0; i < n; ++i) {
      any += notsure[i] = sg[i] == -1;
    }
    if (!any) break;
    solver.solve([&](int pos, int* now) {
      if (notsure[pos] && !*now) {
        sg[pos] = i;
        return 1;
      }
      return 0;
    });
  }
}
int main() {
  std::ios::sync_with_stdio(false), cin.tie(0);
  cin >> n >> f;
  init();
  int all = 0;
  for (int i = 0; i < n; ++i) {
    int a, b, c;
    cin >> a >> b >> c;
    all ^= sg[b - a - 1];
    all ^= sg[c - b - 1];
  }
  if (all) cout << "Alice" << '\n';
  cout << "Bob" << '\n';
  if (!all) cout << "Alice" << '\n';
}
