#include using namespace std; typedef unsigned long long int64; int main(void) { int q; cin >> q; for(int i = 0; i < q; i++) { int64 d, x, t; cin >> d >> x >> t; int64 m = d - 1; int64 n = x + m; m=min(m,n-m); int64 p = 1,bf=0; bool is_out = false; for(int64 j = 1; j <= m; j++) { p *= n - j + 1; p/=j; if(p > t||bf>p) { is_out = true; break; } bf=p; } //cout<