結果
問題 |
No.1072 A Nice XOR Pair
|
ユーザー |
![]() |
提出日時 | 2020-08-18 11:37:16 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
RE
|
実行時間 | - |
コード長 | 289 bytes |
コンパイル時間 | 263 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 27,904 KB |
最終ジャッジ日時 | 2024-10-12 02:35:04 |
合計ジャッジ時間 | 4,008 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 1 RE * 1 |
other | WA * 2 RE * 9 |
ソースコード
def main(): n,x = map(int,input().split()) a = [int(input()) for i in range(n)] b = [] c = [0 for i in range(n + 1)] for i in range(n): b.append(a[i] ^ x) c[a[i]] += 1 cnt = 0 for i in range(n): cnt += c[a[i]] print(cnt // 2) main()