結果
| 問題 | No.2061 XOR Sort |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2022-08-26 23:19:19 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 498 bytes |
| 記録 | |
| コンパイル時間 | 1,066 ms |
| コンパイル使用メモリ | 85,548 KB |
| 実行使用メモリ | 114,560 KB |
| 最終ジャッジ日時 | 2026-05-01 10:39:22 |
| 合計ジャッジ時間 | 6,623 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 16 WA * 25 |
ソースコード
import sys,random,bisect
from collections import deque,defaultdict,Counter
from heapq import heapify,heappop,heappush
from itertools import cycle, permutations
from math import log,gcd
input = lambda :sys.stdin.readline().rstrip()
mi = lambda :map(int,input().split())
li = lambda :list(mi())
N = int(input())
A = li()
res = 1
for i in range(30):
x,y = 0,0
for a in A:
if a>>i & 1:
x += 1
else:
y += 1
if x*y >= 1:
res *= 2
print(res)