#include using namespace std; typedef long long ll; ll q, d, x, t; ll nCk(ll n, ll k, ll mx) { if (k == 0) return 1; ll temp = nCk(n-1, k-1, mx); if (temp > mx) return temp; return nCk(n-1, k-1, mx) * n / k; } int main() { scanf("%lld", &q); for (ll i = 0; i < q; i++) { scanf("%lld%lld%lld", &d, &x, &t); if (nCk(x+d-1, d-1, t) > t) printf("ZETUBOU\n"); else printf("AC\n"); } }