#include #define rep(i,n) for(int i=0;i<(int)(n);i++) using namespace std; using ll = long long ; using P = pair ; using pll = pair; constexpr int INF = 1e9; constexpr long long LINF = 1e17; constexpr int MOD = 1000000007; constexpr double PI = 3.14159265358979323846; #include #include namespace mp = boost::multiprecision; // 任意長整数型 using Bint = mp::cpp_int; // 仮数部が1024ビットの浮動小数点数型(TLEしたら小さくする) using Real = mp::number>; Real fact[100001]; Real mypow(Real x, long long n) { Real ret = 1; while (n > 0) { if (n & 1) ret = (ret * x) ; x = (x * x) ; n >>= 1; } return ret; } int main(){ fact[0] = 1; for(int i=1;i<100001;i++) fact[i] = fact[i-1] * (Real)i; //cout << fact[100000] << endl; int q; cin >> q; while(q--){ int n,m,k; cin >> n >> m >> k; Real com = (fact[n] / fact[k]) / fact[n-k]; Real p = (Real)(n-k+1) * mypow(m,k-1); if(com < p) cout << "Flush" << endl; else cout << "Straight" << endl; } return 0; }