結果

問題 No.723 2つの数の和
ユーザー nebukuro09
提出日時 2018-08-03 22:30:44
言語 Python2
(2.7.18)
結果
AC  
実行時間 133 ms / 2,000 ms
コード長 189 bytes
コンパイル時間 689 ms
コンパイル使用メモリ 7,040 KB
実行使用メモリ 20,300 KB
最終ジャッジ日時 2024-09-19 17:30:08
合計ジャッジ時間 3,059 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 22
権限があれば一括ダウンロードができます

ソースコード

diff #

from collections import Counter
N, X = map(int, raw_input().split())
A = map(int, raw_input().split())
C = Counter(A)
ans = 0

for a in A:
    if X-a in C:
        ans += C[X-a]

print ans
0