結果

問題 No.112 ややこしい鶴亀算
ユーザー ABKZABKZ
提出日時 2022-12-04 21:27:52
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 218 bytes
コンパイル時間 618 ms
コンパイル使用メモリ 82,208 KB
実行使用メモリ 53,636 KB
最終ジャッジ日時 2024-04-20 03:51:52
合計ジャッジ時間 2,393 ms
ジャッジサーバーID
(参考情報)
judge4 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 33 ms
51,936 KB
testcase_01 AC 37 ms
52,356 KB
testcase_02 AC 37 ms
51,872 KB
testcase_03 AC 37 ms
52,644 KB
testcase_04 AC 35 ms
52,984 KB
testcase_05 AC 36 ms
52,756 KB
testcase_06 AC 36 ms
51,952 KB
testcase_07 WA -
testcase_08 AC 36 ms
53,588 KB
testcase_09 AC 39 ms
52,192 KB
testcase_10 AC 38 ms
52,940 KB
testcase_11 AC 36 ms
52,440 KB
testcase_12 AC 37 ms
52,576 KB
testcase_13 AC 36 ms
52,828 KB
testcase_14 AC 37 ms
53,196 KB
testcase_15 AC 38 ms
53,012 KB
testcase_16 AC 34 ms
52,400 KB
testcase_17 WA -
testcase_18 AC 38 ms
52,196 KB
testcase_19 AC 38 ms
52,064 KB
testcase_20 AC 32 ms
52,068 KB
testcase_21 AC 37 ms
51,956 KB
testcase_22 AC 37 ms
52,904 KB
testcase_23 AC 37 ms
52,468 KB
testcase_24 AC 37 ms
52,084 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
A = list(map(int, input().split()))

h = [x for x in A if x == A[0]]

if len(h)*2 + (len(A) - len(h))*4 == A[0] + 2:
    print(f"{len(h)} {len(A)-len(h)}")
else:
    print(f"{len(A)-len(h)} {len(h)}")
0