結果

問題 No.227 簡単ポーカー
ユーザー subteu1157subteu1157
提出日時 2020-03-10 10:59:10
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 25 ms / 5,000 ms
コード長 439 bytes
コンパイル時間 95 ms
コンパイル使用メモリ 12,416 KB
実行使用メモリ 10,880 KB
最終ジャッジ日時 2024-04-27 18:33:17
合計ジャッジ時間 933 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 23 ms
10,624 KB
testcase_01 AC 23 ms
10,880 KB
testcase_02 AC 23 ms
10,624 KB
testcase_03 AC 23 ms
10,752 KB
testcase_04 AC 25 ms
10,752 KB
testcase_05 AC 25 ms
10,624 KB
testcase_06 AC 25 ms
10,752 KB
testcase_07 AC 25 ms
10,880 KB
testcase_08 AC 23 ms
10,624 KB
testcase_09 AC 24 ms
10,624 KB
testcase_10 AC 24 ms
10,752 KB
testcase_11 AC 24 ms
10,624 KB
testcase_12 AC 24 ms
10,752 KB
testcase_13 AC 23 ms
10,624 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

a1,a2,a3,a4,a5 = map(int, input().split())
A = [a1,a2,a3,a4,a5]
cnt = [0,0,0,0,0]

for i in range (5):
    for j in range (5):
        if A[i]==A[j]:
            cnt[i]+=1
    
if cnt.count(3)>1:
    if cnt.count(2)>1:
        print("FULL HOUSE")
    else:
        print("THREE CARD")
else:
    if cnt.count(2)>3:
        print("TWO PAIR")
    if 4>cnt.count(2)>1:
        print("ONE PAIR")
    if cnt.count(2)==0:
        print("NO HAND")
0