#include #include #include #define P(x) cout << x< a(5),v(5); int f3,f2; for(int i=0;i<5;i++){ cin >> a[i]; } for(int i=0;i<5;i++){ v[i] = count(a.begin(), a.end(), a[i]); } if(count(v.begin(), v.end(),3) == 3) f3 = 1; if(count(v.begin(), v.end(),2) == 2) f2 = 1; if(count(v.begin(), v.end(),2) == 4) f2 = 2; if(f3 =1 && f2 ==1) P("FULL HOUSE") else if(f3 ==1) P("THREE CARD") else if(f2 ==2) P("TWO PAIR") else if(f2 ==1) P("ONE PAIR") else P("NO HAND") }