#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  long long n, f, sum = 0;
  cin >> n >> f;
  sum += n + f;
  for (long long i = 0; i < n; i++) {
    long long b, w, r;
    cin >> b >> w >> r;
    sum += b + w + r;
  }
  if (sum & 1) {
    cout << "Alice\nBob\n";
    return 0;
  }
  cout << "Bob\nAlice\n";
  return 0;
}
