#include #include using namespace std; using ll = long long; #define rep(i, s, t) for (ll i = s; i < (ll)(t); i++) #define all(x) begin(x), end(x) template bool chmin(T& x, T y) { return x > y ? (x = y, true) : false; } template bool chmax(T& x, T y) { return x < y ? (x = y, true) : false; } struct io_setup { io_setup() { ios::sync_with_stdio(false); cin.tie(nullptr); cout << fixed << setprecision(15); } } io_setup; void solve() { int n, m; cin >> n >> m; vector> g(n); rep(i, 0, m) { int u, v; cin >> u >> v; u--, v--; g[u].push_back(v); } vector mm(n, vector(2, -1)); auto dfs = [&](auto self, int nw, int p) -> int { if (mm[nw][p] != -1) return mm[nw][p]; mm[nw][p] = 2; int flg = 0; for (int nx : g[nw]) { int tmp = self(self, nx, p ^ 1); if (tmp == 1) continue; if (tmp == 0) { flg = 1; break; } flg = 2; } return mm[nw][p] = flg; }; int res = dfs(dfs, 0, 0); if (res == 0) cout << "Bob\n"; else if (res == 1) cout << "Alice\n"; else cout << "Draw\n"; } int main() { int t = 1; // cin >> t; while (t--) solve(); }