結果

問題 No.723 2つの数の和
ユーザー etale.K3etale.K3
提出日時 2021-05-17 18:33:12
言語 Python3
(3.11.6 + numpy 1.26.0 + scipy 1.11.3)
結果
AC  
実行時間 89 ms / 2,000 ms
コード長 149 bytes
コンパイル時間 133 ms
コンパイル使用メモリ 10,668 KB
実行使用メモリ 23,228 KB
最終ジャッジ日時 2023-07-28 23:16:59
合計ジャッジ時間 3,739 ms
ジャッジサーバーID
(参考情報)
judge14 / judge15
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 19 ms
8,392 KB
testcase_01 AC 19 ms
8,476 KB
testcase_02 AC 18 ms
8,472 KB
testcase_03 AC 66 ms
18,064 KB
testcase_04 AC 89 ms
19,156 KB
testcase_05 AC 78 ms
19,064 KB
testcase_06 AC 80 ms
18,776 KB
testcase_07 AC 45 ms
14,492 KB
testcase_08 AC 48 ms
14,320 KB
testcase_09 AC 84 ms
19,384 KB
testcase_10 AC 42 ms
14,576 KB
testcase_11 AC 24 ms
9,860 KB
testcase_12 AC 54 ms
14,948 KB
testcase_13 AC 88 ms
19,980 KB
testcase_14 AC 34 ms
11,824 KB
testcase_15 AC 44 ms
14,620 KB
testcase_16 AC 61 ms
16,956 KB
testcase_17 AC 76 ms
17,708 KB
testcase_18 AC 49 ms
10,332 KB
testcase_19 AC 68 ms
20,060 KB
testcase_20 AC 18 ms
8,544 KB
testcase_21 AC 19 ms
8,520 KB
testcase_22 AC 19 ms
8,528 KB
testcase_23 AC 72 ms
23,228 KB
testcase_24 AC 37 ms
12,372 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from collections import Counter

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

C = Counter(A)

print(sum([C[X-a] for a in A]))
0