結果
| 問題 | No.227 簡単ポーカー | 
| コンテスト | |
| ユーザー |  yn | 
| 提出日時 | 2015-08-11 01:04:22 | 
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 38 ms / 5,000 ms | 
| コード長 | 559 bytes | 
| コンパイル時間 | 152 ms | 
| コンパイル使用メモリ | 12,800 KB | 
| 実行使用メモリ | 10,880 KB | 
| 最終ジャッジ日時 | 2024-07-18 06:36:21 | 
| 合計ジャッジ時間 | 1,188 ms | 
| ジャッジサーバーID (参考情報) | judge2 / judge4 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | AC * 14 | 
ソースコード
a = list(map(int,input().split()))
a.sort()
sta = a[0]
i = 1
pairs = 0
three = 0
count = 1
while i<5:
    if sta == a[i]:
        count += 1
    else:
        sta = a[i]
        if count == 2:
            pairs += 1
        elif count == 3:
            three += 1
        count = 1
    i += 1
if count == 2:
    pairs += 1
elif count == 3:
    three += 1
if pairs == 1 and three == 1:
    print("FULL HOUSE")
elif three == 1:
    print("THREE CARD")
elif pairs == 2:
    print("TWO PAIR")
elif pairs == 1:
    print("ONE PAIR")
else:
    print("NO HAND")
            
            
            
        