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